diff --git headers/os/interface/Screen.h headers/os/interface/Screen.h
index 58cb2e4..7d1ec94 100644
|
|
public:
|
44 | 44 | |
45 | 45 | const color_map* ColorMap(); |
46 | 46 | |
47 | | status_t GetBitmap(BBitmap** _bitmap, |
| 47 | status_t GetBitmap(BBitmap** bitmap, |
48 | 48 | bool drawCursor = true, |
49 | 49 | BRect* frame = NULL); |
50 | 50 | status_t ReadBitmap(BBitmap* bitmap, |
… |
… |
public:
|
52 | 52 | BRect* frame = NULL); |
53 | 53 | |
54 | 54 | rgb_color DesktopColor(); |
55 | | rgb_color DesktopColor(uint32 index); |
| 55 | rgb_color DesktopColor(uint32 workspace); |
56 | 56 | void SetDesktopColor(rgb_color color, |
57 | 57 | bool makeDefault = true); |
58 | 58 | void SetDesktopColor(rgb_color color, |
59 | | uint32 index, bool makeDefault = true); |
| 59 | uint32 workspace, bool makeDefault = true); |
60 | 60 | |
61 | 61 | status_t ProposeMode(display_mode* target, |
62 | 62 | const display_mode* low, |
63 | 63 | const display_mode* high); |
64 | | status_t GetModeList(display_mode** _modeList, |
65 | | uint32* _count); |
66 | | status_t GetMode(display_mode* _mode); |
| 64 | status_t GetModeList(display_mode** modeList, |
| 65 | uint32* count); |
| 66 | status_t GetMode(display_mode* mode); |
67 | 67 | status_t GetMode(uint32 workspace, |
68 | | display_mode* _mode); |
| 68 | display_mode* mode); |
69 | 69 | status_t SetMode(display_mode* mode, |
70 | 70 | bool makeDefault = false); |
71 | 71 | status_t SetMode(uint32 workspace, |
diff --git src/kits/interface/Screen.cpp src/kits/interface/Screen.cpp
index 7c75a55..bbcb695 100644
|
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | |
11 | | /*! BScreen lets you retrieve and change the display settings. */ |
12 | | |
13 | | |
14 | 11 | #include <Screen.h> |
15 | | |
16 | 12 | #include <Window.h> |
17 | 13 | |
18 | 14 | #include <PrivateScreen.h> |
… |
… |
|
21 | 17 | using namespace BPrivate; |
22 | 18 | |
23 | 19 | |
24 | | /*! \brief Creates a BScreen object which represents the display with the given |
25 | | screen_id |
26 | | \param id The screen_id of the screen to get. |
27 | | |
28 | | In the current implementation, there is only one display (B_MAIN_SCREEN_ID). |
29 | | To be sure that the object was correctly constructed, call IsValid(). |
30 | | */ |
31 | 20 | BScreen::BScreen(screen_id id) |
32 | 21 | { |
33 | 22 | fScreen = BPrivateScreen::Get(id.id); |
34 | 23 | } |
35 | 24 | |
36 | 25 | |
37 | | /*! \brief Creates a BScreen object which represents the display which contains |
38 | | the given BWindow. |
39 | | \param window A BWindow. |
40 | | */ |
41 | 26 | BScreen::BScreen(BWindow* window) |
42 | 27 | { |
43 | 28 | fScreen = BPrivateScreen::Get(window); |
44 | 29 | } |
45 | 30 | |
46 | 31 | |
47 | | /*! \brief Releases the resources allocated by the constructor. |
48 | | */ |
49 | 32 | BScreen::~BScreen() |
50 | 33 | { |
51 | 34 | BPrivateScreen::Put(fScreen); |
52 | 35 | } |
53 | 36 | |
54 | 37 | |
55 | | /*! \brief Checks if the BScreen object represents a real screen connected to |
56 | | the computer. |
57 | | \return \c true if the BScreen object is valid, \c false if not. |
58 | | */ |
59 | 38 | bool |
60 | 39 | BScreen::IsValid() |
61 | 40 | { |
… |
… |
BScreen::IsValid()
|
63 | 42 | } |
64 | 43 | |
65 | 44 | |
66 | | /*! \brief In the current implementation, this function always returns B_ERROR. |
67 | | \return Always \c B_ERROR. |
68 | | */ |
69 | 45 | status_t |
70 | 46 | BScreen::SetToNext() |
71 | 47 | { |
… |
… |
BScreen::SetToNext()
|
80 | 56 | } |
81 | 57 | |
82 | 58 | |
83 | | /*! \brief Returns the color space of the screen display. |
84 | | \return \c B_CMAP8, \c B_RGB15, or \c B_RGB32, or \c B_NO_COLOR_SPACE |
85 | | if the screen object is invalid. |
86 | | */ |
87 | 59 | color_space |
88 | 60 | BScreen::ColorSpace() |
89 | 61 | { |
90 | 62 | if (fScreen != NULL) |
91 | 63 | return fScreen->ColorSpace(); |
| 64 | |
92 | 65 | return B_NO_COLOR_SPACE; |
93 | 66 | } |
94 | 67 | |
95 | 68 | |
96 | | /*! \brief Returns the rectangle that locates the screen in the screen |
97 | | coordinate system. |
98 | | \return a BRect that locates the screen in the screen coordinate system. |
99 | | */ |
100 | 69 | BRect |
101 | 70 | BScreen::Frame() |
102 | 71 | { |
103 | 72 | if (fScreen != NULL) |
104 | 73 | return fScreen->Frame(); |
| 74 | |
105 | 75 | return BRect(0, 0, 0, 0); |
106 | 76 | } |
107 | 77 | |
108 | 78 | |
109 | | /*! \brief Returns the identifier for the screen. |
110 | | \return A screen_id struct that identifies the screen. |
111 | | |
112 | | In the current implementation, this function always returns |
113 | | \c B_MAIN_SCREEN_ID, even if the object is invalid. |
114 | | */ |
115 | 79 | screen_id |
116 | 80 | BScreen::ID() |
117 | 81 | { |
… |
… |
BScreen::ID()
|
124 | 88 | } |
125 | 89 | |
126 | 90 | |
127 | | /*! \brief Blocks until the monitor has finished the current vertical retrace. |
128 | | \return \c B_OK, or \c B_ERROR if the screen object is invalid. |
129 | | */ |
130 | 91 | status_t |
131 | 92 | BScreen::WaitForRetrace() |
132 | 93 | { |
… |
… |
BScreen::WaitForRetrace()
|
134 | 95 | } |
135 | 96 | |
136 | 97 | |
137 | | /*! \brief Blocks until the monitor has finished the current vertical retrace, |
138 | | or until the given timeout has passed. |
139 | | \param timeout A bigtime_t which indicates the time to wait before |
140 | | returning. |
141 | | \return \c B_OK if the monitor has retraced in the given amount of time, |
142 | | \c B_ERROR otherwise. |
143 | | */ |
144 | 98 | status_t |
145 | 99 | BScreen::WaitForRetrace(bigtime_t timeout) |
146 | 100 | { |
147 | 101 | if (fScreen != NULL) |
148 | 102 | return fScreen->WaitForRetrace(timeout); |
| 103 | |
149 | 104 | return B_ERROR; |
150 | 105 | } |
151 | 106 | |
152 | 107 | |
153 | | /*! \brief Returns the index of the 8-bit color that, |
154 | | most closely matches the given 32-bit color. |
155 | | \param r The red value for a 32-bit color. |
156 | | \param g The green value for a 32-bit color. |
157 | | \param b The blue value for a 32-bit color. |
158 | | \param a The alpha value for a 32-bit color. |
159 | | \return An index for a 8-bit color in the screen's color map. |
160 | | */ |
161 | 108 | uint8 |
162 | | BScreen::IndexForColor(uint8 r, uint8 g, uint8 b, uint8 a) |
| 109 | BScreen::IndexForColor(uint8 red, uint8 green, uint8 blue, uint8 alpha) |
163 | 110 | { |
164 | 111 | if (fScreen != NULL) |
165 | | return fScreen->IndexForColor(r, g, b, a); |
| 112 | return fScreen->IndexForColor(red, green, blue, alpha); |
| 113 | |
166 | 114 | return 0; |
167 | 115 | } |
168 | 116 | |
169 | 117 | |
170 | | /*! \brief Returns the 32-bit color representation of a given 8-bit color index. |
171 | | \param index The 8-bit color index to convert. |
172 | | \return A rgb_color struct which represents the given 8-bit color index. |
173 | | */ |
174 | 118 | rgb_color |
175 | 119 | BScreen::ColorForIndex(const uint8 index) |
176 | 120 | { |
177 | 121 | if (fScreen != NULL) |
178 | 122 | return fScreen->ColorForIndex(index); |
| 123 | |
179 | 124 | return rgb_color(); |
180 | 125 | } |
181 | 126 | |
182 | 127 | |
183 | | /*! \brief Returns the "inversion" of the given 8-bit color. |
184 | | \param index An 8-bit color index. |
185 | | \return An 8-bit color index that represents the "inversion" of the given |
186 | | color. |
187 | | */ |
188 | 128 | uint8 |
189 | 129 | BScreen::InvertIndex(uint8 index) |
190 | 130 | { |
191 | 131 | if (fScreen != NULL) |
192 | 132 | return fScreen->InvertIndex(index); |
| 133 | |
193 | 134 | return 0; |
194 | 135 | } |
195 | 136 | |
196 | 137 | |
197 | | /*! \brief Returns the color map of the current display. |
198 | | \return A pointer to the object's color_map. |
199 | | */ |
200 | 138 | const color_map* |
201 | 139 | BScreen::ColorMap() |
202 | 140 | { |
203 | 141 | if (fScreen != NULL) |
204 | 142 | return fScreen->ColorMap(); |
| 143 | |
205 | 144 | return NULL; |
206 | 145 | } |
207 | 146 | |
208 | 147 | |
209 | | /*! \brief Copies the screen's contents into the first argument BBitmap. |
210 | | \param screen_shot A pointer to a BBitmap pointer, where the function will |
211 | | allocate a BBitmap for you. |
212 | | \param draw_cursor Specifies if you want the cursor to be drawn. |
213 | | \param bound Let you specify the area you want copied. If it's NULL, the |
214 | | entire screen is copied. |
215 | | \return \c B_OK if the operation was succesful, \c B_ERROR on failure. |
216 | | */ |
217 | 148 | status_t |
218 | | BScreen::GetBitmap(BBitmap** _bitmap, bool drawCursor, BRect* bounds) |
| 149 | BScreen::GetBitmap(BBitmap** bitmap, bool drawCursor, BRect* bounds) |
219 | 150 | { |
220 | 151 | if (fScreen != NULL) |
221 | | return fScreen->GetBitmap(_bitmap, drawCursor, bounds); |
| 152 | return fScreen->GetBitmap(bitmap, drawCursor, bounds); |
| 153 | |
222 | 154 | return B_ERROR; |
223 | 155 | } |
224 | 156 | |
225 | 157 | |
226 | | /*! \brief Copies the screen's contents into the first argument BBitmap. |
227 | | \param screen_shot A pointer to an allocated BBitmap, where the function |
228 | | will store the screen's content. |
229 | | \param draw_cursor Specifies if you want the cursor to be drawn. |
230 | | \param bound Let you specify the area you want copied. If it's NULL, the |
231 | | entire screen is copied. |
232 | | \return \c B_OK if the operation was succesful, \c B_ERROR on failure. |
233 | | |
234 | | The only difference between this method and GetBitmap() is that ReadBitmap |
235 | | requires you to allocate a BBitmap, while the latter will allocate a BBitmap |
236 | | for you. |
237 | | */ |
238 | 158 | status_t |
239 | | BScreen::ReadBitmap(BBitmap* buffer, bool drawCursor, BRect* bounds) |
| 159 | BScreen::ReadBitmap(BBitmap* bitmap, bool drawCursor, BRect* bounds) |
240 | 160 | { |
241 | 161 | if (fScreen != NULL) |
242 | | return fScreen->ReadBitmap(buffer, drawCursor, bounds); |
| 162 | return fScreen->ReadBitmap(bitmap, drawCursor, bounds); |
| 163 | |
243 | 164 | return B_ERROR; |
244 | 165 | } |
245 | 166 | |
246 | 167 | |
247 | | /*! \brief Returns the color of the desktop. |
248 | | \return An rgb_color structure which is the color of the desktop. |
249 | | */ |
250 | 168 | rgb_color |
251 | 169 | BScreen::DesktopColor() |
252 | 170 | { |
… |
… |
BScreen::DesktopColor()
|
257 | 175 | } |
258 | 176 | |
259 | 177 | |
260 | | /*! \brief Returns the color of the desktop in the given workspace. |
261 | | \param workspace The workspace of which you want to have the color. |
262 | | \return An rgb_color structure which is the color of the desktop in the |
263 | | given workspace. |
264 | | */ |
265 | 178 | rgb_color |
266 | 179 | BScreen::DesktopColor(uint32 workspace) |
267 | 180 | { |
… |
… |
BScreen::DesktopColor(uint32 workspace)
|
272 | 185 | } |
273 | 186 | |
274 | 187 | |
275 | | /*! \brief Set the color of the desktop. |
276 | | \param rgb The color you want to paint the desktop background. |
277 | | \param stick If you pass \c true here, the color will be maintained across |
278 | | boots. |
279 | | */ |
280 | 188 | void |
281 | | BScreen::SetDesktopColor(rgb_color rgb, bool stick) |
| 189 | BScreen::SetDesktopColor(rgb_color color, bool stick) |
282 | 190 | { |
283 | 191 | if (fScreen != NULL) |
284 | | fScreen->SetDesktopColor(rgb, B_CURRENT_WORKSPACE_INDEX, stick); |
| 192 | fScreen->SetDesktopColor(color, B_CURRENT_WORKSPACE_INDEX, stick); |
285 | 193 | } |
286 | 194 | |
287 | 195 | |
288 | | /*! \brief Set the color of the desktop in the given workspace. |
289 | | \param rgb The color you want to paint the desktop background. |
290 | | \param index The workspace you want to change the color. |
291 | | \param stick If you pass \c true here, the color will be maintained across |
292 | | boots. |
293 | | */ |
294 | 196 | void |
295 | | BScreen::SetDesktopColor(rgb_color rgb, uint32 index, bool stick) |
| 197 | BScreen::SetDesktopColor(rgb_color color, uint32 workspace, bool stick) |
296 | 198 | { |
297 | 199 | if (fScreen != NULL) |
298 | | fScreen->SetDesktopColor(rgb, index, stick); |
| 200 | fScreen->SetDesktopColor(color, workspace, stick); |
299 | 201 | } |
300 | 202 | |
301 | 203 | |
302 | | /*! \brief Attempts to adjust the supplied mode so that it's a supported mode. |
303 | | \param target The mode you want to be adjusted. |
304 | | \param low The lower limit you want target to be adjusted. |
305 | | \param high The higher limit you want target to be adjusted. |
306 | | \return |
307 | | - \c B_OK if target (as returned) is supported and falls into the |
308 | | limits. |
309 | | - \c B_BAD_VALUE if target (as returned) is supported but doesn't fall |
310 | | into the limits. |
311 | | - \c B_ERROR if target isn't supported. |
312 | | */ |
313 | 204 | status_t |
314 | 205 | BScreen::ProposeMode(display_mode* target, const display_mode* low, |
315 | 206 | const display_mode* high) |
316 | 207 | { |
317 | 208 | if (fScreen != NULL) |
318 | 209 | return fScreen->ProposeMode(target, low, high); |
| 210 | |
319 | 211 | return B_ERROR; |
320 | 212 | } |
321 | 213 | |
322 | 214 | |
323 | | /*! \brief allocates and returns a list of the display_modes |
324 | | that the graphics card supports. |
325 | | \param mode_list A pointer to a mode_list pointer, where the function will |
326 | | allocate an array of display_mode structures. |
327 | | \param count A pointer to an integer, where the function will store the |
328 | | amount of available display modes. |
329 | | \return \c B_OK. |
330 | | */ |
331 | 215 | status_t |
332 | | BScreen::GetModeList(display_mode** _modeList, uint32* _count) |
| 216 | BScreen::GetModeList(display_mode** modeList, uint32* count) |
333 | 217 | { |
334 | 218 | if (fScreen != NULL) |
335 | | return fScreen->GetModeList(_modeList, _count); |
| 219 | return fScreen->GetModeList(modeList, count); |
| 220 | |
336 | 221 | return B_ERROR; |
337 | 222 | } |
338 | 223 | |
339 | 224 | |
340 | | /*! \brief Copies the current display_mode into mode. |
341 | | \param mode A pointer to a display_mode structure, |
342 | | where the current display_mode will be copied. |
343 | | \return \c B_OK if the operation was succesful. |
344 | | */ |
345 | 225 | status_t |
346 | 226 | BScreen::GetMode(display_mode* mode) |
347 | 227 | { |
348 | 228 | if (fScreen != NULL) |
349 | 229 | return fScreen->GetMode(B_CURRENT_WORKSPACE_INDEX, mode); |
| 230 | |
350 | 231 | return B_ERROR; |
351 | 232 | } |
352 | 233 | |
353 | 234 | |
354 | | /*! \brief Copies the current display_mode of the given workspace into mode. |
355 | | \param workspace The index of the workspace to query. |
356 | | \param mode A pointer to a display_mode structure, |
357 | | where the current display_mode will be copied. |
358 | | \return \c B_OK if the operation was succesful. |
359 | | */ |
360 | 235 | status_t |
361 | 236 | BScreen::GetMode(uint32 workspace, display_mode* mode) |
362 | 237 | { |
363 | 238 | if (fScreen != NULL) |
364 | 239 | return fScreen->GetMode(workspace, mode); |
| 240 | |
365 | 241 | return B_ERROR; |
366 | 242 | } |
367 | 243 | |
368 | 244 | |
369 | | /*! \brief Set the screen to the given mode. |
370 | | \param mode A pointer to a display_mode. |
371 | | \param makeDefault If true, the mode becomes the default for the screen. |
372 | | \return \c B_OK. |
373 | | */ |
374 | 245 | status_t |
375 | 246 | BScreen::SetMode(display_mode* mode, bool makeDefault) |
376 | 247 | { |
377 | 248 | if (fScreen != NULL) |
378 | 249 | return fScreen->SetMode(B_CURRENT_WORKSPACE_INDEX, mode, makeDefault); |
| 250 | |
379 | 251 | return B_ERROR; |
380 | 252 | } |
381 | 253 | |
382 | 254 | |
383 | | /*! \brief Set the given workspace to the given mode. |
384 | | \param workspace The index of the workspace that you want to change. |
385 | | \param mode A pointer to a display_mode. |
386 | | \param makeDefault If true, the mode becomes the default for the workspace. |
387 | | \return \c B_OK. |
388 | | */ |
389 | 255 | status_t |
390 | 256 | BScreen::SetMode(uint32 workspace, display_mode* mode, bool makeDefault) |
391 | 257 | { |
392 | 258 | if (fScreen != NULL) |
393 | 259 | return fScreen->SetMode(workspace, mode, makeDefault); |
| 260 | |
394 | 261 | return B_ERROR; |
395 | 262 | } |
396 | 263 | |
397 | 264 | |
398 | | /*! \brief Returns information about the graphics card. |
399 | | \param info An accelerant_device_info struct where to store the retrieved |
400 | | info. |
401 | | \return \c B_OK if the operation went fine, otherwise an error code. |
402 | | */ |
403 | 265 | status_t |
404 | 266 | BScreen::GetDeviceInfo(accelerant_device_info* info) |
405 | 267 | { |
406 | 268 | if (fScreen != NULL) |
407 | 269 | return fScreen->GetDeviceInfo(info); |
| 270 | |
408 | 271 | return B_ERROR; |
409 | 272 | } |
410 | 273 | |
… |
… |
BScreen::GetMonitorInfo(monitor_info* info)
|
414 | 277 | { |
415 | 278 | if (fScreen != NULL) |
416 | 279 | return fScreen->GetMonitorInfo(info); |
| 280 | |
417 | 281 | return B_ERROR; |
418 | 282 | } |
419 | 283 | |
420 | 284 | |
421 | | /*! \brief Returns, in low and high, the minimum and maximum pixel clock rates |
422 | | that are possible for the given mode. |
423 | | \param mode A pointer to a display_mode. |
424 | | \param low A pointer to an int where the function will store the lowest |
425 | | available pixel clock. |
426 | | \param high A pointer to an int where the function wills tore the highest |
427 | | available pixel clock. |
428 | | \return \c B_OK if the operation went fine, otherwise an error code. |
429 | | */ |
430 | 285 | status_t |
431 | | BScreen::GetPixelClockLimits(display_mode* mode, uint32* _low, uint32* _high) |
| 286 | BScreen::GetPixelClockLimits(display_mode* mode, uint32* low, uint32* high) |
432 | 287 | { |
433 | 288 | if (fScreen != NULL) |
434 | | return fScreen->GetPixelClockLimits(mode, _low, _high); |
| 289 | return fScreen->GetPixelClockLimits(mode, low, high); |
| 290 | |
435 | 291 | return B_ERROR; |
436 | 292 | } |
437 | 293 | |
438 | 294 | |
439 | | /*! \brief Fills out the dtc structure with the timing constraints of the |
440 | | current display mode. |
441 | | \param dtc A pointer to a display_timing_constraints structure where the |
442 | | function will store the timing constraints of the current mode. |
443 | | \return \c B_OK if the operation went fine, otherwise an error code. |
444 | | */ |
445 | 295 | status_t |
446 | 296 | BScreen::GetTimingConstraints(display_timing_constraints* constraints) |
447 | 297 | { |
448 | 298 | if (fScreen != NULL) |
449 | 299 | return fScreen->GetTimingConstraints(constraints); |
| 300 | |
450 | 301 | return B_ERROR; |
451 | 302 | } |
452 | 303 | |
453 | 304 | |
454 | | /*! \brief Lets you set the VESA Display Power Management Signaling state for |
455 | | the screen. |
456 | | \param dpms_state The DPMS state you want to be set. |
457 | | valid values are: |
458 | | - \c B_DPMS_ON |
459 | | - \c B_DPMS_STAND_BY |
460 | | - \c B_DPMS_SUSPEND |
461 | | - \c B_DPMS_OFF |
462 | | \return \c B_OK if the operation went fine, otherwise an error code. |
463 | | */ |
464 | 305 | status_t |
465 | 306 | BScreen::SetDPMS(uint32 dpmsState) |
466 | 307 | { |
467 | 308 | if (fScreen != NULL) |
468 | 309 | return fScreen->SetDPMS(dpmsState); |
| 310 | |
469 | 311 | return B_ERROR; |
470 | 312 | } |
471 | 313 | |
472 | 314 | |
473 | | /*! \brief Returns the current DPMS state of the screen. |
474 | | */ |
475 | 315 | uint32 |
476 | 316 | BScreen::DPMSState() |
477 | 317 | { |
478 | 318 | if (fScreen != NULL) |
479 | 319 | return fScreen->DPMSState(); |
| 320 | |
480 | 321 | return 0; |
481 | 322 | } |
482 | 323 | |
483 | 324 | |
484 | | /*! \brief Indicates which DPMS modes the monitor supports. |
485 | | */ |
486 | 325 | uint32 |
487 | 326 | BScreen::DPMSCapabilites() |
488 | 327 | { |
489 | 328 | if (fScreen != NULL) |
490 | 329 | return fScreen->DPMSCapabilites(); |
| 330 | |
491 | 331 | return 0; |
492 | 332 | } |
493 | 333 | |
… |
… |
BScreen::DPMSCapabilites()
|
495 | 335 | // #pragma mark - Deprecated methods |
496 | 336 | |
497 | 337 | |
498 | | /*! \brief Returns the BPrivateScreen used by the BScreen object. |
499 | | \return A pointer to the BPrivateScreen class internally used by the BScreen |
500 | | object. |
501 | | */ |
502 | 338 | BPrivate::BPrivateScreen* |
503 | 339 | BScreen::private_screen() |
504 | 340 | { |
… |
… |
BScreen::private_screen()
|
506 | 342 | } |
507 | 343 | |
508 | 344 | |
509 | | /*! \brief Deprecated, use ProposeMode() instead. |
510 | | */ |
511 | 345 | status_t |
512 | 346 | BScreen::ProposeDisplayMode(display_mode* target, const display_mode* low, |
513 | 347 | const display_mode* high) |
… |
… |
BScreen::ProposeDisplayMode(display_mode* target, const display_mode* low,
|
516 | 350 | } |
517 | 351 | |
518 | 352 | |
519 | | /*! \brief Returns the base address of the framebuffer. |
520 | | */ |
521 | 353 | void* |
522 | 354 | BScreen::BaseAddress() |
523 | 355 | { |
524 | 356 | if (fScreen != NULL) |
525 | 357 | return fScreen->BaseAddress(); |
| 358 | |
526 | 359 | return NULL; |
527 | 360 | } |
528 | 361 | |
529 | 362 | |
530 | | /*! \brief Returns the amount of bytes per row of the framebuffer. |
531 | | */ |
532 | 363 | uint32 |
533 | 364 | BScreen::BytesPerRow() |
534 | 365 | { |
535 | 366 | if (fScreen != NULL) |
536 | 367 | return fScreen->BytesPerRow(); |
| 368 | |
537 | 369 | return 0; |
538 | 370 | } |