Start of actual filling in of wxFrame. Makefile now supports tiff
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@6097 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -27,6 +27,7 @@
|
|||||||
|
|
||||||
#if wxUSE_STATUSBAR
|
#if wxUSE_STATUSBAR
|
||||||
#include "wx/statusbr.h"
|
#include "wx/statusbr.h"
|
||||||
|
#include "wx/generic/statusbr.h"
|
||||||
#endif // wxUSE_STATUSBAR
|
#endif // wxUSE_STATUSBAR
|
||||||
|
|
||||||
#if wxUSE_TOOLBAR
|
#if wxUSE_TOOLBAR
|
||||||
@@ -81,88 +82,126 @@ void wxFrame::Init()
|
|||||||
#if wxUSE_TOOLTIPS
|
#if wxUSE_TOOLTIPS
|
||||||
m_hwndToolTip = 0;
|
m_hwndToolTip = 0;
|
||||||
#endif
|
#endif
|
||||||
}
|
// Data to save/restore when calling ShowFullScreen
|
||||||
|
m_lFsStyle = 0L;
|
||||||
|
m_lFsOldWindowStyle = 0L;
|
||||||
|
m_nFsStatusBarFields = 0;
|
||||||
|
m_nFsStatusBarHeight = 0;
|
||||||
|
m_nFsToolBarHeight = 0;
|
||||||
|
m_bFsIsMaximized = FALSE;
|
||||||
|
m_bFsIsShowing = FALSE;
|
||||||
|
} // end of wxFrame::Init
|
||||||
|
|
||||||
bool wxFrame::Create(wxWindow *parent,
|
bool wxFrame::Create(
|
||||||
wxWindowID id,
|
wxWindow* pParent
|
||||||
const wxString& title,
|
, wxWindowID vId
|
||||||
const wxPoint& pos,
|
, const wxString& rsTitle
|
||||||
const wxSize& size,
|
, const wxPoint& rPos
|
||||||
long style,
|
, const wxSize& rSize
|
||||||
const wxString& name)
|
, long lStyle
|
||||||
|
, const wxString& rsName
|
||||||
|
)
|
||||||
{
|
{
|
||||||
SetName(name);
|
int nX = rPos.x;
|
||||||
m_windowStyle = style;
|
int nY = rPos.y;
|
||||||
m_frameMenuBar = NULL;
|
int nWidth = rSize.x;
|
||||||
m_frameToolBar = NULL;
|
int nHeight = rSize.y;
|
||||||
m_frameStatusBar = NULL;
|
SWP vSwp;
|
||||||
|
|
||||||
SetBackgroundColour(wxSystemSettings::GetSystemColour(wxSYS_COLOUR_APPWORKSPACE));
|
SetName(rsName);
|
||||||
|
m_windowStyle = lStyle;
|
||||||
|
m_frameMenuBar = NULL;
|
||||||
|
m_frameToolBar = NULL;
|
||||||
|
m_frameStatusBar = NULL;
|
||||||
|
|
||||||
if ( id > -1 )
|
SetBackgroundColour(wxSystemSettings::GetSystemColour(wxSYS_COLOUR_APPWORKSPACE));
|
||||||
m_windowId = id;
|
|
||||||
else
|
|
||||||
m_windowId = (int)NewControlId();
|
|
||||||
|
|
||||||
if (parent) parent->AddChild(this);
|
if (vId > -1 )
|
||||||
|
m_windowId = vId;
|
||||||
|
else
|
||||||
|
m_windowId = (int)NewControlId();
|
||||||
|
|
||||||
int x = pos.x;
|
if (pParent)
|
||||||
int y = pos.y;
|
pParent->AddChild(this);
|
||||||
int width = size.x;
|
|
||||||
int height = size.y;
|
|
||||||
|
|
||||||
m_iconized = FALSE;
|
m_bIconized = FALSE;
|
||||||
|
|
||||||
// we pass NULL as parent to MSWCreate because frames with parents behave
|
//
|
||||||
// very strangely under Win95 shell
|
// We pass NULL as parent to MSWCreate because frames with parents behave
|
||||||
// Alteration by JACS: keep normal Windows behaviour (float on top of parent)
|
// very strangely under Win95 shell.
|
||||||
// with this style.
|
// Alteration by JACS: keep normal Windows behaviour (float on top of parent)
|
||||||
if ((m_windowStyle & wxFRAME_FLOAT_ON_PARENT) == 0)
|
// with this style.
|
||||||
parent = NULL;
|
//
|
||||||
|
if ((m_windowStyle & wxFRAME_FLOAT_ON_PARENT) == 0)
|
||||||
|
pParent = NULL;
|
||||||
|
|
||||||
if (!parent)
|
if (!pParent)
|
||||||
wxTopLevelWindows.Append(this);
|
wxTopLevelWindows.Append(this);
|
||||||
|
|
||||||
OS2Create(m_windowId, parent, wxFrameClassName, this, title,
|
OS2Create( m_windowId
|
||||||
x, y, width, height, style);
|
,pParent
|
||||||
|
,wxFrameClassName
|
||||||
|
,this
|
||||||
|
,rsTitle
|
||||||
|
,nX
|
||||||
|
,nY
|
||||||
|
,nWidth
|
||||||
|
,nHeight
|
||||||
|
,lStyle
|
||||||
|
);
|
||||||
|
|
||||||
wxModelessWindows.Append(this);
|
wxModelessWindows.Append(this);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
} // end of wxFrame::Create
|
||||||
|
|
||||||
wxFrame::~wxFrame()
|
wxFrame::~wxFrame()
|
||||||
{
|
{
|
||||||
m_isBeingDeleted = TRUE;
|
m_isBeingDeleted = TRUE;
|
||||||
wxTopLevelWindows.DeleteObject(this);
|
wxTopLevelWindows.DeleteObject(this);
|
||||||
|
|
||||||
// TODO:
|
DeleteAllBars();
|
||||||
/*
|
|
||||||
DeleteAllBars();
|
|
||||||
|
|
||||||
if (wxTheApp && (wxTopLevelWindows.Number() == 0))
|
if (wxTheApp && (wxTopLevelWindows.Number() == 0))
|
||||||
{
|
|
||||||
wxTheApp->SetTopWindow(NULL);
|
|
||||||
|
|
||||||
if (wxTheApp->GetExitOnFrameDelete())
|
|
||||||
{
|
{
|
||||||
PostQuitMessage(0);
|
wxTheApp->SetTopWindow(NULL);
|
||||||
|
|
||||||
|
if (wxTheApp->GetExitOnFrameDelete())
|
||||||
|
{
|
||||||
|
::WinPostMsg(m_hwnd, WM_QUIT, 0, 0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
wxModelessWindows.DeleteObject(this);
|
||||||
|
|
||||||
wxModelessWindows.DeleteObject(this);
|
//
|
||||||
|
// For some reason, wxWindows can activate another task altogether
|
||||||
// For some reason, wxWindows can activate another task altogether
|
// when a frame is destroyed after a modal dialog has been invoked.
|
||||||
// when a frame is destroyed after a modal dialog has been invoked.
|
// Try to bring the parent to the top.
|
||||||
// Try to bring the parent to the top.
|
//
|
||||||
// MT:Only do this if this frame is currently the active window, else weird
|
// MT:Only do this if this frame is currently the active window, else weird
|
||||||
// things start to happen
|
// things start to happen.
|
||||||
if ( wxGetActiveWindow() == this )
|
//
|
||||||
if (GetParent() && GetParent()->GetHWND())
|
if (wxGetActiveWindow() == this)
|
||||||
::BringWindowToTop((HWND) GetParent()->GetHWND());
|
{
|
||||||
*/
|
if (GetParent() && GetParent()->GetHWND())
|
||||||
}
|
{
|
||||||
|
::WinQueryWindowPos( (HWND) GetParent()->GetHWND()
|
||||||
|
,&vSwp
|
||||||
|
);
|
||||||
|
::WinSetWindowPos( (HWND) GetParent()->GetHWND()
|
||||||
|
,HWND_TOP
|
||||||
|
,vSwp.x
|
||||||
|
,vSwp.y
|
||||||
|
,vSwp.cx
|
||||||
|
,vSwp,cy
|
||||||
|
,SWP_ACTIVATE | SWP_MOVE | SWP_SIZE | SWP_SHOW
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} // end of wxFrame::~wxFrame
|
||||||
|
|
||||||
|
//
|
||||||
// Get size *available for subwindows* i.e. excluding menu bar, toolbar etc.
|
// Get size *available for subwindows* i.e. excluding menu bar, toolbar etc.
|
||||||
|
//
|
||||||
void wxFrame::DoGetClientSize(int *x, int *y) const
|
void wxFrame::DoGetClientSize(int *x, int *y) const
|
||||||
{
|
{
|
||||||
// TODO:
|
// TODO:
|
||||||
|
@@ -573,7 +573,7 @@ HTMLLIBOBJS = \
|
|||||||
OBJECTS = $(COMMONOBJS) $(GENERICOBJS) $(HTMLOBJS) $(NONESSENTIALOBJS) $(OS2OBJS)
|
OBJECTS = $(COMMONOBJS) $(GENERICOBJS) $(HTMLOBJS) $(NONESSENTIALOBJS) $(OS2OBJS)
|
||||||
|
|
||||||
# Normal, static library
|
# Normal, static library
|
||||||
all: $(DUMMYOBJ) $(OBJECTS) $(PERIPH_TARGET) png zlib jpeg xpm $(LIBTARGET)
|
all: $(DUMMYOBJ) $(OBJECTS) $(PERIPH_TARGET) png zlib jpeg xpm tiff $(LIBTARGET)
|
||||||
|
|
||||||
dirs: $(OS2DIR)\$D $(COMMDIR)\$D $(GENDIR)\$D $(HTMLDIR)\$D
|
dirs: $(OS2DIR)\$D $(COMMDIR)\$D $(GENDIR)\$D $(HTMLDIR)\$D
|
||||||
|
|
||||||
@@ -1027,7 +1027,17 @@ clean_xpm:
|
|||||||
nmake -f makefile.va clean
|
nmake -f makefile.va clean
|
||||||
cd $(WXDIR)\src\os2
|
cd $(WXDIR)\src\os2
|
||||||
|
|
||||||
clean: $(PERIPH_CLEAN_TARGET) clean_png clean_zlib clean_jpeg clean_xpm
|
tiff:
|
||||||
|
cd $(WXDIR)\src\tiff
|
||||||
|
nmake -f makefile.va FINAL=$(FINAL) DLL=$(DLL) WXMAKINGDLL=$(WXMAKINGDLL)
|
||||||
|
cd $(WXDIR)\src\os2
|
||||||
|
|
||||||
|
clean_tiff:
|
||||||
|
cd $(WXDIR)\src\tiff
|
||||||
|
nmake -f makefile.va clean
|
||||||
|
cd $(WXDIR)\src\os2
|
||||||
|
|
||||||
|
clean: $(PERIPH_CLEAN_TARGET) clean_png clean_zlib clean_jpeg clean_xpm clean_tiff
|
||||||
del $(LIBTARGET)
|
del $(LIBTARGET)
|
||||||
!if "$(WXMAKINGDLL)" == "1"
|
!if "$(WXMAKINGDLL)" == "1"
|
||||||
erase /N ..\..\lib\wx200.lib
|
erase /N ..\..\lib\wx200.lib
|
||||||
|
Reference in New Issue
Block a user