diff --git a/indra/llcommon/llsys.cpp b/indra/llcommon/llsys.cpp
index 0272c55db21a812978de298b25463be1dd13429b..cb91a54f11c36a3b06a87737975e215dc36b7da2 100644
--- a/indra/llcommon/llsys.cpp
+++ b/indra/llcommon/llsys.cpp
@@ -775,6 +775,34 @@ 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 c2c45bec9a2a01ea8ce735a70d4d0995176a0a56..aa3fdd485bca84d7c6088daaf80890be06a5edf6 100644
--- a/indra/llcommon/llsys.h
+++ b/indra/llcommon/llsys.h
@@ -122,6 +122,21 @@ class LL_COMMON_API LLMemoryInfo
 	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);
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp
index 948d38befb7d4c89e4fa876948c19b663386aac2..6d4c90c2b95a9b368dc8c10c58f73fccacecdf90 100644
--- a/indra/newview/llappviewer.cpp
+++ b/indra/newview/llappviewer.cpp
@@ -304,7 +304,8 @@ static std::string gLaunchFileOnQuit;
 
 // Used on Win32 for other apps to identify our window (eg, win_setup)
 const char* const VIEWER_WINDOW_CLASSNAME = "Second Life";
-
+static const S32 FIRST_RUN_WINDOW_WIDTH = 1024;
+static const S32 FIRST_RUN_WINDOW_HRIGHT = 768;
 //----------------------------------------------------------------------------
 
 // List of entries from strings.xml to always replace
@@ -2362,12 +2363,35 @@ bool LLAppViewer::initWindow()
 	// store setting in a global for easy access and modification
 	gNoRender = gSavedSettings.getBOOL("DisableRendering");
 
+	S32 window_x = gSavedSettings.getS32("WindowX");
+	S32 window_y = gSavedSettings.getS32("WindowY");
+	S32 window_width = gSavedSettings.getS32("WindowWidth");
+	S32 window_height = gSavedSettings.getS32("WindowHeight");
+
+	bool show_maximized = gSavedSettings.getBOOL("WindowMaximized");
+
+	bool first_run = gSavedSettings.getBOOL("FirstLoginThisInstall");
+
+	if (first_run)//for first login 
+	{
+		window_width = FIRST_RUN_WINDOW_WIDTH;//yep hardcoded
+		window_height = FIRST_RUN_WINDOW_HRIGHT;
+		
+		//if screen resolution is lower then 1024*768 then show maximized
+		LLDisplayInfo display_info;
+		if(display_info.getDisplayWidth() <= FIRST_RUN_WINDOW_WIDTH
+			|| display_info.getDisplayHeight()<=FIRST_RUN_WINDOW_HRIGHT)
+		{
+			show_maximized = true;
+		}
+	}
+
 	// always start windowed
 	BOOL ignorePixelDepth = gSavedSettings.getBOOL("IgnorePixelDepth");
 	gViewerWindow = new LLViewerWindow(gWindowTitle, 
 		VIEWER_WINDOW_CLASSNAME,
-		gSavedSettings.getS32("WindowX"), gSavedSettings.getS32("WindowY"),
-		gSavedSettings.getS32("WindowWidth"), gSavedSettings.getS32("WindowHeight"),
+		window_x, window_y,
+		window_width, window_height,
 		FALSE, ignorePixelDepth);
 
 	LLNotificationsUI::LLNotificationManager::getInstance();
@@ -2378,7 +2402,7 @@ bool LLAppViewer::initWindow()
 		gViewerWindow->toggleFullscreen(FALSE);
 	}
 	
-	if (gSavedSettings.getBOOL("WindowMaximized"))
+	if (show_maximized)
 	{
 		gViewerWindow->mWindow->maximize();
 		gViewerWindow->getWindow()->setNativeAspectRatio(gSavedSettings.getF32("FullScreenAspectRatio"));