xref: /haiku/src/kits/screensaver/ScreenSaver.cpp (revision 99d027cd0238c1d86da86d7c3f4200509ccc61a6)
1 /*
2  * Copyright 2003-2006, Michael Phipps. All rights reserved.
3  * Distributed under the terms of the MIT License.
4  */
5 
6 
7 #include "ScreenSaver.h"
8 
9 
10 BScreenSaver::BScreenSaver(BMessage *archive, image_id thisImage)
11 	:
12 	fTickSize(50000),
13 	fLoopOnCount(0),
14 	fLoopOffCount(0)
15 {
16 }
17 
18 
19 BScreenSaver::~BScreenSaver()
20 {
21 }
22 
23 
24 status_t
25 BScreenSaver::InitCheck()
26 {
27     // This method is meant to be overridden
28     return B_OK;
29 }
30 
31 
32 status_t
33 BScreenSaver::StartSaver(BView *view, bool preview)
34 {
35     // This method is meant to be overridden
36     return B_OK;
37 }
38 
39 
40 void
41 BScreenSaver::StopSaver()
42 {
43 	// This method is meant to be overridden
44 	return;
45 }
46 
47 
48 void
49 BScreenSaver::Draw(BView *view, int32 frame)
50 {
51 	// This method is meant to be overridden
52 	return;
53 }
54 
55 
56 void
57 BScreenSaver::DirectConnected(direct_buffer_info *info)
58 {
59 	// This method is meant to be overridden
60 	return;
61 }
62 
63 
64 void
65 BScreenSaver::DirectDraw(int32 frame)
66 {
67 	// This method is meant to be overridden
68 	return;
69 }
70 
71 
72 void
73 BScreenSaver::StartConfig(BView *configView)
74 {
75 	// This method is meant to be overridden
76 	return;
77 }
78 
79 
80 void
81 BScreenSaver::StopConfig()
82 {
83 	// This method is meant to be overridden
84 	return;
85 }
86 
87 
88 void
89 BScreenSaver::SupplyInfo(BMessage* info) const
90 {
91 	// This method is meant to be overridden
92 	return;
93 }
94 
95 
96 void
97 BScreenSaver::ModulesChanged(const BMessage* info)
98 {
99 	// This method is meant to be overridden
100 	return;
101 }
102 
103 
104 status_t
105 BScreenSaver::SaveState(BMessage *into) const
106 {
107     // This method is meant to be overridden
108     return B_ERROR;
109 }
110 
111 
112 void
113 BScreenSaver::SetTickSize(bigtime_t tickSize)
114 {
115 	fTickSize = tickSize;
116 }
117 
118 
119 bigtime_t
120 BScreenSaver::TickSize() const
121 {
122     return fTickSize;
123 }
124 
125 
126 void
127 BScreenSaver::SetLoop(int32 onCount, int32 offCount)
128 {
129 	fLoopOnCount = onCount;
130 	fLoopOffCount = offCount;
131 }
132 
133 
134 int32
135 BScreenSaver::LoopOnCount() const
136 {
137     return fLoopOnCount;
138 }
139 
140 
141 int32
142 BScreenSaver::LoopOffCount() const
143 {
144     return fLoopOffCount;
145 }
146 
147 
148 void BScreenSaver::_ReservedScreenSaver1() {}
149 void BScreenSaver::_ReservedScreenSaver2() {}
150 void BScreenSaver::_ReservedScreenSaver3() {}
151 void BScreenSaver::_ReservedScreenSaver4() {}
152 void BScreenSaver::_ReservedScreenSaver5() {}
153 void BScreenSaver::_ReservedScreenSaver6() {}
154 void BScreenSaver::_ReservedScreenSaver7() {}
155 void BScreenSaver::_ReservedScreenSaver8() {}
156 
157 // for compatibility with older BeOS versions
158 extern "C" {
159 void ReservedScreenSaver1__12BScreenSaver() {}
160 void ReservedScreenSaver2__12BScreenSaver() {}
161 void ReservedScreenSaver3__12BScreenSaver() {}
162 void ReservedScreenSaver4__12BScreenSaver() {}
163 void ReservedScreenSaver5__12BScreenSaver() {}
164 void ReservedScreenSaver6__12BScreenSaver() {}
165 void ReservedScreenSaver7__12BScreenSaver() {}
166 void ReservedScreenSaver8__12BScreenSaver() {}
167 }
168