diff options
Diffstat (limited to 'linden/indra/llwindow/llwindow.h')
-rw-r--r-- | linden/indra/llwindow/llwindow.h | 32 |
1 files changed, 14 insertions, 18 deletions
diff --git a/linden/indra/llwindow/llwindow.h b/linden/indra/llwindow/llwindow.h index a63c8d5..cee83b9 100644 --- a/linden/indra/llwindow/llwindow.h +++ b/linden/indra/llwindow/llwindow.h | |||
@@ -32,8 +32,6 @@ | |||
32 | #ifndef LL_LLWINDOW_H | 32 | #ifndef LL_LLWINDOW_H |
33 | #define LL_LLWINDOW_H | 33 | #define LL_LLWINDOW_H |
34 | 34 | ||
35 | #include <sys/stat.h> | ||
36 | |||
37 | #include "llrect.h" | 35 | #include "llrect.h" |
38 | #include "llcoord.h" | 36 | #include "llcoord.h" |
39 | #include "llstring.h" | 37 | #include "llstring.h" |
@@ -121,6 +119,7 @@ public: | |||
121 | virtual void handleDataCopy(LLWindow *window, S32 data_type, void *data); | 119 | virtual void handleDataCopy(LLWindow *window, S32 data_type, void *data); |
122 | virtual BOOL handleTimerEvent(LLWindow *window); | 120 | virtual BOOL handleTimerEvent(LLWindow *window); |
123 | virtual BOOL handleDeviceChange(LLWindow *window); | 121 | virtual BOOL handleDeviceChange(LLWindow *window); |
122 | virtual void handlePingWatchdog(LLWindow *window, const char * msg); | ||
124 | }; | 123 | }; |
125 | 124 | ||
126 | // Refer to llwindow_test in test/common/llwindow for usage example | 125 | // Refer to llwindow_test in test/common/llwindow for usage example |
@@ -197,10 +196,6 @@ public: | |||
197 | virtual void bringToFront() = 0; | 196 | virtual void bringToFront() = 0; |
198 | virtual void focusClient() { }; // this may not have meaning or be required on other platforms, therefore, it's not abstract | 197 | virtual void focusClient() { }; // this may not have meaning or be required on other platforms, therefore, it's not abstract |
199 | 198 | ||
200 | virtual S32 stat( const char* file_name, struct stat* stat_info ) = 0; | ||
201 | virtual BOOL sendEmail(const char* address,const char* subject,const char* body_text, const char* attachment=NULL, const char* attachment_displayed_name=NULL ) = 0; | ||
202 | |||
203 | |||
204 | // handy coordinate space conversion routines | 199 | // handy coordinate space conversion routines |
205 | // NB: screen to window and vice verse won't work on width/height coordinate pairs, | 200 | // NB: screen to window and vice verse won't work on width/height coordinate pairs, |
206 | // as the conversion must take into account left AND right border widths, etc. | 201 | // as the conversion must take into account left AND right border widths, etc. |
@@ -225,14 +220,18 @@ public: | |||
225 | // opens system default color picker | 220 | // opens system default color picker |
226 | virtual BOOL dialog_color_picker (F32 *r, F32 *g, F32 *b) { return FALSE; }; | 221 | virtual BOOL dialog_color_picker (F32 *r, F32 *g, F32 *b) { return FALSE; }; |
227 | 222 | ||
228 | // return a platform-specific window reference (HWND on Windows, WindowRef on the Mac) | 223 | // return a platform-specific window reference (HWND on Windows, WindowRef on the Mac, Gtk window on Linux) |
229 | virtual void *getPlatformWindow() = 0; | 224 | virtual void *getPlatformWindow() = 0; |
225 | |||
226 | // return the platform-specific window reference we use to initialize llmozlib (HWND on Windows, WindowRef on the Mac, Gtk window on Linux) | ||
227 | virtual void *getMediaWindow(); | ||
230 | 228 | ||
231 | // control platform's Language Text Input mechanisms. | 229 | // control platform's Language Text Input mechanisms. |
232 | virtual void allowLanguageTextInput(LLPreeditor *preeditor, BOOL b) {} | 230 | virtual void allowLanguageTextInput(LLPreeditor *preeditor, BOOL b) {} |
233 | virtual void setLanguageTextInput( const LLCoordGL & pos ) {}; | 231 | virtual void setLanguageTextInput( const LLCoordGL & pos ) {}; |
234 | virtual void updateLanguageTextInputArea() {} | 232 | virtual void updateLanguageTextInputArea() {} |
235 | virtual void interruptLanguageTextInput() {} | 233 | virtual void interruptLanguageTextInput() {} |
234 | virtual void spawnWebBrowser(const std::string& escaped_url) {}; | ||
236 | 235 | ||
237 | static std::string getFontListSans(); | 236 | static std::string getFontListSans(); |
238 | 237 | ||
@@ -293,13 +292,13 @@ public: | |||
293 | static LLSplashScreen * create(); | 292 | static LLSplashScreen * create(); |
294 | static void show(); | 293 | static void show(); |
295 | static void hide(); | 294 | static void hide(); |
296 | static void update(const char* string); | 295 | static void update(const std::string& string); |
297 | 296 | ||
298 | static bool isVisible(); | 297 | static bool isVisible(); |
299 | protected: | 298 | protected: |
300 | // These are overridden by the platform implementation | 299 | // These are overridden by the platform implementation |
301 | virtual void showImpl() = 0; | 300 | virtual void showImpl() = 0; |
302 | virtual void updateImpl(const char* string) = 0; | 301 | virtual void updateImpl(const std::string& string) = 0; |
303 | virtual void hideImpl() = 0; | 302 | virtual void hideImpl() = 0; |
304 | 303 | ||
305 | static BOOL sVisible; | 304 | static BOOL sVisible; |
@@ -307,7 +306,7 @@ protected: | |||
307 | }; | 306 | }; |
308 | 307 | ||
309 | // Platform-neutral for accessing the platform specific message box | 308 | // Platform-neutral for accessing the platform specific message box |
310 | S32 OSMessageBox(const char* text, const char* caption, U32 type); | 309 | S32 OSMessageBox(const std::string& text, const std::string& caption, U32 type); |
311 | const U32 OSMB_OK = 0; | 310 | const U32 OSMB_OK = 0; |
312 | const U32 OSMB_OKCANCEL = 1; | 311 | const U32 OSMB_OKCANCEL = 1; |
313 | const U32 OSMB_YESNO = 2; | 312 | const U32 OSMB_YESNO = 2; |
@@ -325,8 +324,8 @@ class LLWindowManager | |||
325 | { | 324 | { |
326 | public: | 325 | public: |
327 | static LLWindow* createWindow( | 326 | static LLWindow* createWindow( |
328 | char *title, | 327 | const std::string& title, |
329 | char *name, | 328 | const std::string& name, |
330 | LLCoordScreen upper_left = LLCoordScreen(10, 10), | 329 | LLCoordScreen upper_left = LLCoordScreen(10, 10), |
331 | LLCoordScreen size = LLCoordScreen(320, 240), | 330 | LLCoordScreen size = LLCoordScreen(320, 240), |
332 | U32 flags = 0, | 331 | U32 flags = 0, |
@@ -336,7 +335,7 @@ public: | |||
336 | BOOL use_gl = TRUE, | 335 | BOOL use_gl = TRUE, |
337 | BOOL ignore_pixel_depth = FALSE); | 336 | BOOL ignore_pixel_depth = FALSE); |
338 | static LLWindow *createWindow( | 337 | static LLWindow *createWindow( |
339 | char* title, char* name, S32 x, S32 y, S32 width, S32 height, | 338 | const std::string& title, const std::string& name, S32 x, S32 y, S32 width, S32 height, |
340 | U32 flags = 0, | 339 | U32 flags = 0, |
341 | BOOL fullscreen = FALSE, | 340 | BOOL fullscreen = FALSE, |
342 | BOOL clearBg = FALSE, | 341 | BOOL clearBg = FALSE, |
@@ -355,11 +354,8 @@ extern BOOL gDebugWindowProc; | |||
355 | 354 | ||
356 | // Protocols, like "http" and "https" we support in URLs | 355 | // Protocols, like "http" and "https" we support in URLs |
357 | extern const S32 gURLProtocolWhitelistCount; | 356 | extern const S32 gURLProtocolWhitelistCount; |
358 | extern const char* gURLProtocolWhitelist[]; | 357 | extern const std::string gURLProtocolWhitelist[]; |
359 | extern const char* gURLProtocolWhitelistHandler[]; | 358 | extern const std::string gURLProtocolWhitelistHandler[]; |
360 | |||
361 | // Loads a URL with the user's default browser | ||
362 | void spawn_web_browser(const char* escaped_url); | ||
363 | 359 | ||
364 | void simpleEscapeString ( std::string& stringIn ); | 360 | void simpleEscapeString ( std::string& stringIn ); |
365 | 361 | ||