summaryrefslogtreecommitdiff
path: root/indra/llwindow
diff options
context:
space:
mode:
authorIgor Borovkov <iborovkov@productengine.com>2010-03-18 16:38:44 +0200
committerIgor Borovkov <iborovkov@productengine.com>2010-03-18 16:38:44 +0200
commit11e4b42ec97df4154c29814e9568d43faab90cce (patch)
tree9f827558afb8d6720292823d883a94e6fcb2c239 /indra/llwindow
parentf318d936467113b94f654121f40cc0f0a9f4c3a4 (diff)
parentc67bc96278ea76372d896fb82fc6f3557feac446 (diff)
merge
--HG-- branch : product-engine
Diffstat (limited to 'indra/llwindow')
-rw-r--r--indra/llwindow/llwindow.cpp27
-rw-r--r--indra/llwindow/llwindow.h15
-rw-r--r--indra/llwindow/llwindowmacosx-objc.h1
-rw-r--r--indra/llwindow/llwindowmacosx-objc.mm9
-rw-r--r--indra/llwindow/llwindowmacosx.cpp20
-rw-r--r--indra/llwindow/llwindowmacosx.h2
-rw-r--r--indra/llwindow/llwindowsdl.cpp41
-rw-r--r--indra/llwindow/llwindowsdl.h3
-rw-r--r--indra/llwindow/llwindowwin32.cpp11
-rw-r--r--indra/llwindow/llwindowwin32.h3
10 files changed, 0 insertions, 132 deletions
diff --git a/indra/llwindow/llwindow.cpp b/indra/llwindow/llwindow.cpp
index b77deb003f..1c6c9e6e9d 100644
--- a/indra/llwindow/llwindow.cpp
+++ b/indra/llwindow/llwindow.cpp
@@ -407,30 +407,3 @@ BOOL LLWindowManager::isWindowValid(LLWindow *window)
{
return sWindowList.find(window) != sWindowList.end();
}
-
-S32 LLDisplayInfo::getDisplayWidth() const
-{
-#if LL_WINDOWS
- return LLWindowWin32::getDisplayWidth();
-#elif LL_DARWIN
- return LLWindowMacOSX::getDisplayWidth();
-#elif LL_SDL
- return LLWindowSDL::getDisplayWidth();
-#else
- return 1024; //*FIXME
-#endif
-}
-
-S32 LLDisplayInfo::getDisplayHeight() const
-{
-#if LL_WINDOWS
- return LLWindowWin32::getDisplayHeight();
-#elif LL_DARWIN
- return LLWindowMacOSX::getDisplayHeight();
-#elif LL_SDL
- return LLWindowSDL::getDisplayHeight();
-#else
- return 768; //*FIXME
-#endif
-}
-
diff --git a/indra/llwindow/llwindow.h b/indra/llwindow/llwindow.h
index b769f5071b..55b221e716 100644
--- a/indra/llwindow/llwindow.h
+++ b/indra/llwindow/llwindow.h
@@ -281,19 +281,4 @@ extern const std::string gURLProtocolWhitelistHandler[];
void simpleEscapeString ( std::string& stringIn );
-//=============================================================================
-//
-// CLASS LLDisplayInfo
-class LLDisplayInfo
-
-/*! @brief Class to query the information about some display settings
-*/
-{
-public:
- LLDisplayInfo(){}; ///< Default constructor
-
- S32 getDisplayWidth() const; ///< display width
- S32 getDisplayHeight() const; ///< display height
-};
-
#endif // _LL_window_h_
diff --git a/indra/llwindow/llwindowmacosx-objc.h b/indra/llwindow/llwindowmacosx-objc.h
index 66851300d4..ed5d7b1e74 100644
--- a/indra/llwindow/llwindowmacosx-objc.h
+++ b/indra/llwindow/llwindowmacosx-objc.h
@@ -40,5 +40,4 @@ void setupCocoa();
CursorRef createImageCursor(const char *fullpath, int hotspotX, int hotspotY);
OSErr releaseImageCursor(CursorRef ref);
OSErr setImageCursor(CursorRef ref);
-void getScreenSize(int* width, int* height);
diff --git a/indra/llwindow/llwindowmacosx-objc.mm b/indra/llwindow/llwindowmacosx-objc.mm
index 6eca24ec1d..59b25e1726 100644
--- a/indra/llwindow/llwindowmacosx-objc.mm
+++ b/indra/llwindow/llwindowmacosx-objc.mm
@@ -116,12 +116,3 @@ OSErr setImageCursor(CursorRef ref)
return noErr;
}
-void getScreenSize(int* width, int* height)
-{
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
- NSRect screen_rect = [[NSScreen mainScreen] frame];
- if (width) *width = (int)(screen_rect.size.width);
- if (height) *height = (int)(screen_rect.size.height);
- [pool release];
-}
-
diff --git a/indra/llwindow/llwindowmacosx.cpp b/indra/llwindow/llwindowmacosx.cpp
index d7e912f19b..022b97f481 100644
--- a/indra/llwindow/llwindowmacosx.cpp
+++ b/indra/llwindow/llwindowmacosx.cpp
@@ -3473,26 +3473,6 @@ MASK LLWindowMacOSX::modifiersToMask(SInt16 modifiers)
return mask;
}
-// static
-S32 LLWindowMacOSX::getDisplayWidth()
-{
- S32 width = 1024;
- // Need to invoke cocoa before use getScreenSize()
- setupCocoa();
- getScreenSize(&width, NULL);
- return width;
-}
-
-// static
-S32 LLWindowMacOSX::getDisplayHeight()
-{
- S32 height = 768;
- // Need to invoke cocoa before use getScreenSize()
- setupCocoa();
- getScreenSize(NULL, &height);
- return height;
-}
-
#if LL_OS_DRAGDROP_ENABLED
OSErr LLWindowMacOSX::dragTrackingHandler(DragTrackingMessage message, WindowRef theWindow,
diff --git a/indra/llwindow/llwindowmacosx.h b/indra/llwindow/llwindowmacosx.h
index 86036a261c..7c6b324029 100644
--- a/indra/llwindow/llwindowmacosx.h
+++ b/indra/llwindow/llwindowmacosx.h
@@ -123,8 +123,6 @@ public:
// Provide native key event data
/*virtual*/ LLSD getNativeKeyData();
- static S32 getDisplayWidth();
- static S32 getDisplayHeight();
protected:
LLWindowMacOSX(LLWindowCallbacks* callbacks,
diff --git a/indra/llwindow/llwindowsdl.cpp b/indra/llwindow/llwindowsdl.cpp
index fe0ada5b09..1f705f9e60 100644
--- a/indra/llwindow/llwindowsdl.cpp
+++ b/indra/llwindow/llwindowsdl.cpp
@@ -187,47 +187,6 @@ Display* LLWindowSDL::get_SDL_Display(void)
}
#endif // LL_X11
-// static
-S32 LLWindowSDL::getDisplayWidth()
-{
-#if LL_GTK
- if (LLWindowSDL::ll_try_gtk_init())
- {
- return gdk_screen_width();
- }
-#endif // LL_GTK
-
-#if LL_X11
- Display *display = XOpenDisplay(NULL);
- int screen_num = DefaultScreen(display);
- S32 width = DisplayWidth(display, screen_num);
- XCloseDisplay(display);
- return width;
-#endif //LL_X11
-
- return 1024;
-}
-
-// static
-S32 LLWindowSDL::getDisplayHeight()
-{
-#if LL_GTK
- if (LLWindowSDL::ll_try_gtk_init())
- {
- return gdk_screen_height();
- }
-#endif // LL_GTK
-
-#if LL_X11
- Display *display = XOpenDisplay(NULL);
- int screen_num = DefaultScreen(display);
- S32 height = DisplayHeight(display, screen_num);
- XCloseDisplay(display);
- return height;
-#endif //LL_X11
-
- return 768;
-}
LLWindowSDL::LLWindowSDL(LLWindowCallbacks* callbacks,
const std::string& title, S32 x, S32 y, S32 width,
diff --git a/indra/llwindow/llwindowsdl.h b/indra/llwindow/llwindowsdl.h
index 2311a361fa..e6bdd46a77 100644
--- a/indra/llwindow/llwindowsdl.h
+++ b/indra/llwindow/llwindowsdl.h
@@ -148,9 +148,6 @@ public:
static Display* get_SDL_Display(void);
#endif // LL_X11
- static S32 getDisplayWidth();
- static S32 getDisplayHeight();
-
protected:
LLWindowSDL(LLWindowCallbacks* callbacks,
const std::string& title, int x, int y, int width, int height, U32 flags,
diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp
index 5f778d6208..8df9dad581 100644
--- a/indra/llwindow/llwindowwin32.cpp
+++ b/indra/llwindow/llwindowwin32.cpp
@@ -3720,16 +3720,5 @@ std::vector<std::string> LLWindowWin32::getDynamicFallbackFontList()
return std::vector<std::string>();
}
-// static
-S32 LLWindowWin32::getDisplayWidth()
-{
- return ::GetSystemMetrics(SM_CXVIRTUALSCREEN);
-}
-
-// static
-S32 LLWindowWin32::getDisplayHeight()
-{
- return ::GetSystemMetrics(SM_CYVIRTUALSCREEN);
-}
#endif // LL_WINDOWS
diff --git a/indra/llwindow/llwindowwin32.h b/indra/llwindow/llwindowwin32.h
index c221ec0192..9d57735772 100644
--- a/indra/llwindow/llwindowwin32.h
+++ b/indra/llwindow/llwindowwin32.h
@@ -120,9 +120,6 @@ public:
static std::vector<std::string> getDynamicFallbackFontList();
- static S32 getDisplayWidth();
- static S32 getDisplayHeight();
-
protected:
LLWindowWin32(LLWindowCallbacks* callbacks,
const std::string& title, const std::string& name, int x, int y, int width, int height, U32 flags,