From c67bc96278ea76372d896fb82fc6f3557feac446 Mon Sep 17 00:00:00 2001
From: Igor Borovkov <iborovkov@productengine.com>
Date: Thu, 18 Mar 2010 16:31:09 +0200
Subject: Backed out changeset f4c0761897c6  EXT-4820([NUX] Viewer dimensions
 on first-run)

by which "moved LLDisplayInfo to llwindow, implemented getting the width/height of screen for mac os and linux."

--HG--
branch : product-engine
---
 indra/llcommon/llsys.cpp | 27 +++++++++++++++++++++++++++
 indra/llcommon/llsys.h   | 16 ++++++++++++++++
 2 files changed, 43 insertions(+)

(limited to 'indra/llcommon')

diff --git a/indra/llcommon/llsys.cpp b/indra/llcommon/llsys.cpp
index 0272c55db2..0ed700b9da 100644
--- a/indra/llcommon/llsys.cpp
+++ b/indra/llcommon/llsys.cpp
@@ -775,6 +775,33 @@ void LLMemoryInfo::stream(std::ostream& s) const
 #endif
 }
 
+S32 LLDisplayInfo::getDisplayWidth() const
+{
+#if LL_WINDOWS
+	return  ::GetSystemMetrics(SM_CXVIRTUALSCREEN);
+#elif LL_DARWIN
+	return 1024; //*FIXME
+#elif LL_SOLARIS
+	return 1024; //*FIXME
+#else
+	return 1024; //*FIXME
+#endif
+}
+
+S32 LLDisplayInfo::getDisplayHeight() const
+{
+#if LL_WINDOWS
+	return  ::GetSystemMetrics(SM_CYVIRTUALSCREEN);
+#elif LL_DARWIN
+	return 768; //*FIXME
+#elif LL_SOLARIS
+	return 768; //*FIXME
+#else
+	return 768; //*FIXME
+#endif
+}
+
+
 std::ostream& operator<<(std::ostream& s, const LLOSInfo& info)
 {
 	info.stream(s);
diff --git a/indra/llcommon/llsys.h b/indra/llcommon/llsys.h
index f1dda1b2e2..aa3fdd485b 100644
--- a/indra/llcommon/llsys.h
+++ b/indra/llcommon/llsys.h
@@ -122,6 +122,22 @@ public:
 	U32 getPhysicalMemoryClamped() const; ///< Memory size in clamped bytes
 };
 
+//=============================================================================
+//
+//	CLASS		LLDisplayInfo
+class LL_COMMON_API 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
+	
+};
+
 LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLOSInfo& info);
 LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLCPUInfo& info);
 LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLMemoryInfo& info);
-- 
cgit v1.2.3