summaryrefslogtreecommitdiff
path: root/indra/llwindow
diff options
context:
space:
mode:
authorJosh Bell <josh@lindenlab.com>2007-01-04 02:04:29 +0000
committerJosh Bell <josh@lindenlab.com>2007-01-04 02:04:29 +0000
commitd60f16540dba5616cd8260046b44ebc2a1047065 (patch)
treeab241efaf58ba4eeb1916763cef337a04bc15d64 /indra/llwindow
parent0434d35c160bcd0d78b8f4e795a62155f50a6fb8 (diff)
svn merge svn+ssh://svn.lindenlab.com/svn/linden/release@56429 svn+ssh://svn.lindenlab.com/svn/linden/branches/maintenance@56431
This turned up the following "lost" changes: llapp.cpp (from maintenance r55371) - SIGPIPE fix, possibly llfontgl.cpp (from maintenance r50207) - whitespace only inventorybridge.cpp (property - non-executable) skins/xui/*/* (from maintenance r55380) - XML processing instruction went AWOL
Diffstat (limited to 'indra/llwindow')
-rw-r--r--indra/llwindow/llkeyboardwin32.cpp6
-rw-r--r--indra/llwindow/llwindow.cpp4
-rw-r--r--indra/llwindow/llwindow.h13
-rw-r--r--indra/llwindow/llwindowwin32.cpp17
-rw-r--r--indra/llwindow/llwindowwin32.h7
5 files changed, 17 insertions, 30 deletions
diff --git a/indra/llwindow/llkeyboardwin32.cpp b/indra/llwindow/llkeyboardwin32.cpp
index 6f5383428e..ddc099418c 100644
--- a/indra/llwindow/llkeyboardwin32.cpp
+++ b/indra/llwindow/llkeyboardwin32.cpp
@@ -9,9 +9,15 @@
#if LL_WINDOWS
#include "linden_common.h"
+
#include "llkeyboardwin32.h"
+
#include "llwindow.h"
+#define WIN32_LEAN_AND_MEAN
+#include <winsock2.h>
+#include <windows.h>
+
LLKeyboardWin32::LLKeyboardWin32()
{
// Set up key mapping for windows - eventually can read this from a file?
diff --git a/indra/llwindow/llwindow.cpp b/indra/llwindow/llwindow.cpp
index 21774fe233..d5e1e77053 100644
--- a/indra/llwindow/llwindow.cpp
+++ b/indra/llwindow/llwindow.cpp
@@ -23,6 +23,7 @@
#include "llerror.h"
#include "llkeyboard.h"
+#include "linked_lists.h"
//static instance for default callbacks
LLWindowCallbacks LLWindow::sDefaultCallbacks;
@@ -305,7 +306,8 @@ void LLSplashScreen::hide()
// LLWindowManager
//
-LLLinkedList<LLWindow> LLWindowManager::sWindowList;
+// TODO: replace with std::set
+static LLLinkedList<LLWindow> sWindowList;
LLWindow* LLWindowManager::createWindow(
char *title,
diff --git a/indra/llwindow/llwindow.h b/indra/llwindow/llwindow.h
index 703eee32d0..442f4c9667 100644
--- a/indra/llwindow/llwindow.h
+++ b/indra/llwindow/llwindow.h
@@ -12,7 +12,6 @@
#include <sys/stat.h>
#include "llrect.h"
-#include "linked_lists.h"
#include "llcoord.h"
#include "llstring.h"
@@ -272,9 +271,6 @@ const S32 OSBTN_CANCEL = 3;
class LLWindowManager
{
-private:
- static LLLinkedList<LLWindow> sWindowList;
-
public:
static LLWindow* createWindow(
char *title,
@@ -316,13 +312,4 @@ void shell_open(const char* file_path);
void simpleEscapeString ( std::string& stringIn );
-
-#if LL_WINDOWS
- // return Win32 specific window handle
- HWND llwindow_get_hwnd(LLWindow *window);
-
- // backdoor for special case handling of Win32 messages
- void llwindow_install_wndproc(LLWindow *window, WNDPROC wnd_proc);
-#endif
-
#endif // _LL_window_h_
diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp
index ad56b97577..daa1a26b3d 100644
--- a/indra/llwindow/llwindowwin32.cpp
+++ b/indra/llwindow/llwindowwin32.cpp
@@ -10,6 +10,8 @@
#if LL_WINDOWS && !LL_MESA_HEADLESS
+#include "llwindowwin32.h"
+
#include <commdlg.h>
#include <WinUser.h>
#include <mapi.h>
@@ -20,7 +22,7 @@
#define DIRECTINPUT_VERSION 0x0800
#include <dinput.h>
-#include "llwindowwin32.h"
+
#include "llkeyboardwin32.h"
#include "llerror.h"
#include "llgl.h"
@@ -3023,19 +3025,6 @@ LRESULT CALLBACK LLSplashScreenWin32::windowProc(HWND h_wnd, UINT u_msg,
// Helper Funcs
//
-HWND llwindow_get_hwnd(LLWindow *window)
-{
- //assumes we are dealing with a Win32 window
- return ((LLWindowWin32*)window)->mWindowHandle;
-}
-
-
-void llwindow_install_wndproc(LLWindow *window, WNDPROC wnd_proc)
-{
- //assumes we are dealing with a Win32 window
- ((LLWindowWin32*)window)->mWndProc = wnd_proc;
-}
-
S32 OSMessageBoxWin32(const char* text, const char* caption, U32 type)
{
UINT uType;
diff --git a/indra/llwindow/llwindowwin32.h b/indra/llwindow/llwindowwin32.h
index 6803ad6f2a..0b6fd5157a 100644
--- a/indra/llwindow/llwindowwin32.h
+++ b/indra/llwindow/llwindowwin32.h
@@ -9,6 +9,11 @@
#ifndef LL_LLWINDOWWIN32_H
#define LL_LLWINDOWWIN32_H
+// Limit Windows API to small and manageable set.
+#define WIN32_LEAN_AND_MEAN
+#include <winsock2.h>
+#include <windows.h>
+
#include "llwindow.h"
// Hack for async host by name
@@ -152,8 +157,6 @@ protected:
BOOL mMousePositionModified;
BOOL mInputProcessingPaused;
- friend HWND llwindow_get_hwnd(LLWindow *window);
- friend void llwindow_install_wndproc(LLWindow *window, WNDPROC wnd_proc);
friend class LLWindowManager;
};