]> git.saurik.com Git - wxWidgets.git/commitdiff
Removed every usage of obsolete wxTLW flags. 2.6 compatibility markup for them.
authorWłodzimierz Skiba <abx@abx.art.pl>
Fri, 31 Mar 2006 18:07:22 +0000 (18:07 +0000)
committerWłodzimierz Skiba <abx@abx.art.pl>
Fri, 31 Mar 2006 18:07:22 +0000 (18:07 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@38477 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

36 files changed:
contrib/docs/latex/fl/body.tex
contrib/samples/deprecated/resource/dialog1.wxr
contrib/samples/fl/fl_demo1.cpp
contrib/samples/fl/fl_sample1.cpp
contrib/samples/fl/fl_sample2.cpp
contrib/samples/fl/fl_sample3.cpp
contrib/samples/ogl/studio/studio_resources.wxr
contrib/src/deprecated/resource.cpp
contrib/utils/convertrc/rc2wxr.cpp
contrib/utils/convertrc/wxr2xml.cpp
docs/latex/wx/tstyles.tex
include/wx/cocoa/dialog.h
include/wx/motif/dialog.h
include/wx/toplevel.h
samples/dnd/dnd.cpp
samples/html/test/f.html
src/generic/busyinfo.cpp
src/generic/dbgrptg.cpp
src/generic/textdlgg.cpp
src/motif/dialog.cpp
src/motif/toplevel.cpp
src/msw/dialog.cpp
src/msw/frame.cpp
src/msw/mdi.cpp
src/os2/dc.cpp
src/os2/toplevel.cpp
src/palmos/dialog.cpp
src/palmos/frame.cpp
src/univ/topluniv.cpp
src/x11/toplevel.cpp
src/xrc/xh_dlg.cpp
src/xrc/xh_frame.cpp
src/xrc/xh_mdi.cpp
src/xrc/xh_panel.cpp
src/xrc/xh_scwin.cpp
src/xrc/xh_sizer.cpp

index a900fd7dda8fd57c39f570c65e2f158496f14d78..e2cb8e4c09642d86bb57c6a97acd62ce60018ca2 100644 (file)
@@ -1,3 +1,14 @@
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%% Name:        body.tex
+%% Purpose:     FL documenation
+%% Author:      wxWidgets Team
+%% Modified by:
+%% Created:
+%% RCS-ID:      $Id$
+%% Copyright:   (c) wxWidgets Team
+%% License:     wxWindows license
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 \chapter{Introduction}\label{introduction}
 \pagenumbering{arabic}%
 \setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
@@ -109,53 +120,53 @@ user interface as illustrated in \helpref{What is FL?}{whatisfl}.
 #include "wx/fl/dyntbarhnd.h"    // control-bar dimension handler for it
 
 MyFrame::MyFrame(wxFrame *frame)
-    : wxFrame( frame, -1, "wxWindows 2.0 wxFrameLayout Test Application", wxDefaultPosition, 
-          wxSize( 700, 500 ), 
-          wxCLIP_CHILDREN | wxMINIMIZE_BOX | wxMAXIMIZE_BOX | 
-          wxTHICK_FRAME   | wxSYSTEM_MENU  | wxCAPTION, 
+    : wxFrame( frame, wxID_ANY, "wxWindows 2.0 wxFrameLayout Test Application", wxDefaultPosition,
+          wxSize( 700, 500 ),
+          wxCLIP_CHILDREN | wxMINIMIZE_BOX | wxMAXIMIZE_BOX |
+          wxRESIZE_BORDER | wxSYSTEM_MENU  | wxCAPTION,
           "freimas" )
 {
     mpClientWnd = CreateTextCtrl( "Client window" );
-    
+
     mpLayout = new wxFrameLayout( this, mpClientWnd );
-    
+
     mpLayout->SetUpdatesManager( new cbGCUpdatesMgr() );
-    
+
     // setup plugins for testing
     mpLayout->PushDefaultPlugins();
-    
+
     mpLayout->AddPlugin( CLASSINFO( cbBarHintsPlugin ) ); // fancy "X"es and bevel for bars
     mpLayout->AddPlugin( CLASSINFO( cbHintAnimationPlugin ) );
     mpLayout->AddPlugin( CLASSINFO( cbRowDragPlugin  ) );
     mpLayout->AddPlugin( CLASSINFO( cbAntiflickerPlugin ) );
     mpLayout->AddPlugin( CLASSINFO( cbSimpleCustomizationPlugin ) );
-    
+
     // drop in some bars
-    cbDimInfo sizes0( 200,45, // when docked horizontally      
-                      200,85, // when docked vertically        
-                      175,35, // when floated                  
+    cbDimInfo sizes0( 200,45, // when docked horizontally
+                      200,85, // when docked vertically
+                      175,35, // when floated
                       FALSE,  // the bar is not fixed-size
                       4,      // vertical gap (bar border)
                       4       // horizontal gap (bar border)
-                    ); 
-    
-    cbDimInfo sizes1( 150,35, // when docked horizontally      
-                      150,85, // when docked vertically        
-                      175,35, // when floated                  
+                    );
+
+    cbDimInfo sizes1( 150,35, // when docked horizontally
+                      150,85, // when docked vertically
+                      175,35, // when floated
                       TRUE,   // the bar is not fixed-size
                       4,      // vertical gap (bar border)
                       4       // horizontal gap (bar border)
-                    ); 
-    
-    cbDimInfo sizes2( 175,45, // when docked horizontally      
-                      175,37, // when docked vertically        
-                      170,35, // when floated                  
+                    );
+
+    cbDimInfo sizes2( 175,45, // when docked horizontally
+                      175,37, // when docked vertically
+                      170,35, // when floated
                       TRUE,   // the bar is not fixed-size
                       4,      // vertical gap (bar border)
                       4,      // horizontal gap (bar border)
                       new cbDynToolBarDimHandler()
-                    ); 
-    
+                    );
+
     mpLayout->AddBar( CreateTextCtrl("Hello"),  // bar window
                       sizes0, FL_ALIGN_TOP,     // alignment ( 0-top,1-bottom, etc)
                       0,                        // insert into 0th row (vert. position)
@@ -163,7 +174,7 @@ MyFrame::MyFrame(wxFrame *frame)
                       "InfoViewer1",            // name for reference in customization pop-ups
                       TRUE
                     );
-    
+
     mpLayout->AddBar( CreateTextCtrl("Bye"),    // bar window
                       sizes0, FL_ALIGN_TOP,     // alignment ( 0-top,1-bottom, etc)
                       1,                        // insert into 0th row (vert. position)
@@ -171,7 +182,7 @@ MyFrame::MyFrame(wxFrame *frame)
                       "InfoViewer2",            // name for reference in customization pop-ups
                       TRUE
                     );
-    
+
     mpLayout->AddBar( CreateTextCtrl("Fixed0"), // bar window
                       sizes1, FL_ALIGN_TOP,     // alignment ( 0-top,1-bottom, etc)
                       0,                        // insert into 0th row (vert. position)
@@ -179,21 +190,21 @@ MyFrame::MyFrame(wxFrame *frame)
                       "ToolBar1",               // name for reference in customization pop-ups
                       TRUE
                     );
-    
+
     wxDynamicToolBar* pToolBar = new wxDynamicToolBar();
-    
+
     pToolBar->Create( this, -1 );
-    
+
     // 1001-1006 ids of command events fired by added tool-buttons
-    
+
     pToolBar->AddTool( 1001, BMP_DIR "new.bmp" );
     pToolBar->AddTool( 1002, BMP_DIR "open.bmp" );
     pToolBar->AddTool( 1003, BMP_DIR "save.bmp" );
-    
+
     pToolBar->AddTool( 1004, BMP_DIR "cut.bmp" );
     pToolBar->AddTool( 1005, BMP_DIR "copy.bmp" );
-    pToolBar->AddTool( 1006, BMP_DIR "paste.bmp" );   
-    
+    pToolBar->AddTool( 1006, BMP_DIR "paste.bmp" );
+
     mpLayout->AddBar( pToolBar,             // bar window (can be NULL)
                       sizes2, FL_ALIGN_TOP, // alignment ( 0-top,1-bottom, etc)
                       0,                    // insert into 0th row (vert. position)
@@ -201,13 +212,13 @@ MyFrame::MyFrame(wxFrame *frame)
                       "ToolBar2",           // name for reference in customization pop-ups
                       FALSE
                     );
-    
+
     mpLayout->EnableFloating( TRUE ); // off, thinking about wxGtk...
 }
 
 MyFrame::~MyFrame()
 {
-    if ( mpLayout) 
+    if ( mpLayout)
         delete mpLayout; // should be destroyed manually
 }
 \end{verbatim}
@@ -256,4 +267,3 @@ through the underlaying panes, docking itself in and out in real time.
 Otherwise the stationary bars would be pushed around messing up the composition permanently.
 This flag is irelevant when {\it mRealTimeUpdatesOn} is FALSE, as the ghost-rect
 does not do any docking until the drag finishes.
-
index 4a48e75a465831e9cd375b015b0253badb22fb00..e94249bc36ec4f4492965ec72340a4ce5089a389 100644 (file)
@@ -1,5 +1,5 @@
 static char *dialog1 = "dialog(name = 'dialog1',\
-  style = 'wxRAISED_BORDER | wxCAPTION | wxTHICK_FRAME | wxSYSTEM_MENU',\
+  style = 'wxRAISED_BORDER | wxCAPTION | wxRESIZE_BORDER | wxSYSTEM_MENU',\
   title = 'Test dialog box',\
   id = 100,\
   x = 10, y = 10, width = 210, height = 145,\
index a64759708937d47dc1da5a62b64d3a3415d39458..5b568334f9b8ff87aaa1bd9287447f6e4c62ac7a 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        No names yet.
+// Name:        fl_demo1.cpp
 // Purpose:     Contrib. demo
 // Author:      Aleksandras Gluchovas
 // Modified by: Sebastian Haase (June 21, 2001)
@@ -124,7 +124,7 @@ MyFrame::MyFrame(wxFrame *frame)
     : wxFrame( frame, wxID_ANY, _("wxWidgets 2.0 wxFrameLayout Test Application"), wxDefaultPosition,
           wxSize( 700, 500 ),
           wxCLIP_CHILDREN | wxMINIMIZE_BOX | wxMAXIMIZE_BOX |
-          wxTHICK_FRAME   | wxSYSTEM_MENU  | wxCAPTION | wxCLOSE_BOX,
+          wxRESIZE_BORDER   | wxSYSTEM_MENU  | wxCAPTION | wxCLOSE_BOX,
           wxT("freimas") )
 {
     mpClientWnd = CreateTextCtrl( _("Client window") );
index a9a95d0b16dd56d173146b519ae69053845a54ba..aaa5ae945b2115d41423c060b3527e4d93961e05 100644 (file)
@@ -107,7 +107,7 @@ MyFrame::MyFrame( wxWindow* parent, const wxChar *title )
     : wxFrame( parent, wxID_ANY, title, wxDefaultPosition,
           wxSize( 700, 500 ),
           wxCLIP_CHILDREN | wxMINIMIZE_BOX | wxMAXIMIZE_BOX |
-          wxTHICK_FRAME   | wxSYSTEM_MENU  | wxCAPTION | wxCLOSE_BOX,
+          wxRESIZE_BORDER   | wxSYSTEM_MENU  | wxCAPTION | wxCLOSE_BOX,
           wxT("freimas") )
 {
     mpInternalFrm = (wxPanel*)this;
@@ -195,4 +195,3 @@ void MyFrame::OnQuit( wxCommandEvent& WXUNUSED(event) )
 
     Close(true);
 }
-
index b682647cd6c34d458359399c5ca69c74e8b0c4f2..74c4ede313fa8ac31c07a02cc9e5c6ef6b4ad41d 100644 (file)
@@ -108,7 +108,7 @@ MyFrame::MyFrame( wxWindow* parent, const wxChar *title )
     : wxFrame( parent, wxID_ANY, title, wxDefaultPosition,
           wxSize( 700, 500 ),
           wxCLIP_CHILDREN | wxMINIMIZE_BOX | wxMAXIMIZE_BOX |
-          wxTHICK_FRAME   | wxSYSTEM_MENU  | wxCAPTION | wxCLOSE_BOX,
+          wxRESIZE_BORDER   | wxSYSTEM_MENU  | wxCAPTION | wxCLOSE_BOX,
           wxT("freimas") )
 {
 }
@@ -193,4 +193,3 @@ void MyFrame::OnQuit( wxCommandEvent& WXUNUSED(event) )
 
     Close(true);
 }
-
index 904dcb6deb100d28313bf8b694020c20eac63cbd..60816e95030026a7814f61a1ee42057dbc450094 100644 (file)
@@ -113,7 +113,7 @@ MyFrame::MyFrame( wxWindow* parent, const wxChar *title )
     : wxFrame( parent, wxID_ANY, title, wxDefaultPosition,
           wxSize( 700, 500 ),
           wxCLIP_CHILDREN | wxMINIMIZE_BOX | wxMAXIMIZE_BOX |
-          wxTHICK_FRAME   | wxSYSTEM_MENU  | wxCAPTION | wxCLOSE_BOX,
+          wxRESIZE_BORDER   | wxSYSTEM_MENU  | wxCAPTION | wxCLOSE_BOX,
           wxT("freimas") )
 {
 
@@ -336,4 +336,3 @@ void MyFrame::OnButt2( wxCommandEvent& WXUNUSED(event) )
     }
     i++;
 }
-
index 51c9521bd541b6eef5a342c4b46eea2c78435063..b5b240a20a7082173d46390618e96f24813bb9e8 100644 (file)
@@ -172,7 +172,7 @@ static char *triangle = "dialog(name = 'triangle',\
   control = [5112, wxTextCtrl, '1', '0', 'textctrl2', 227, 213, 40, 19, '1']).";
 
 static char *shape_label_dialog = "dialog(name = 'shape_label_dialog',\
-  style = 'wxRAISED_BORDER | wxCAPTION | wxTHICK_FRAME | wxSYSTEM_MENU',\
+  style = 'wxRAISED_BORDER | wxCAPTION | wxRESIZE_BORDER | wxSYSTEM_MENU',\
   title = 'Edit Shape Label',\
   id = 6008,\
   x = 10, y = 10, width = 190, height = 60,\
index b8836dd8afeeb791138aed4b701ae167e9df9fe1..c3ba5992199ee75e07fe34b552be5b4b17f46a7f 100644 (file)
 #endif // VC++
 
 #ifndef WX_PRECOMP
-#include "wx/defs.h"
-#include "wx/setup.h"
-#include "wx/list.h"
-#include "wx/hash.h"
-#include "wx/gdicmn.h"
-#include "wx/utils.h"
-#include "wx/types.h"
-#include "wx/menu.h"
-#include "wx/stattext.h"
-#include "wx/button.h"
-#include "wx/bmpbuttn.h"
-#include "wx/radiobox.h"
-#include "wx/listbox.h"
-#include "wx/choice.h"
-#include "wx/checkbox.h"
-#include "wx/settings.h"
-#include "wx/slider.h"
-#include "wx/icon.h"
-#include "wx/statbox.h"
-#include "wx/statbmp.h"
-#include "wx/gauge.h"
-#include "wx/textctrl.h"
-#include "wx/msgdlg.h"
-#include "wx/intl.h"
+    #include "wx/list.h"
+    #include "wx/hash.h"
+    #include "wx/gdicmn.h"
+    #include "wx/utils.h"
+    #include "wx/types.h"
+    #include "wx/menu.h"
+    #include "wx/stattext.h"
+    #include "wx/button.h"
+    #include "wx/bmpbuttn.h"
+    #include "wx/radiobox.h"
+    #include "wx/listbox.h"
+    #include "wx/choice.h"
+    #include "wx/checkbox.h"
+    #include "wx/settings.h"
+    #include "wx/slider.h"
+    #include "wx/icon.h"
+    #include "wx/statbox.h"
+    #include "wx/statbmp.h"
+    #include "wx/gauge.h"
+    #include "wx/textctrl.h"
+    #include "wx/msgdlg.h"
+    #include "wx/intl.h"
 #endif
 
 #include "wx/treebase.h"
@@ -708,6 +706,9 @@ wxItemResource *wxResourceInterpretDialog(wxResourceTable& table, wxExpr *expr,
     }
     dialogItem->SetStyle(windowStyle);
     dialogItem->SetValue1(isModal);
+
+#if WXWIN_COMPATIBILITY_2_6
+
 #ifdef __VMS
 #pragma message disable CODCAUUNR
 #endif
@@ -717,6 +718,8 @@ wxItemResource *wxResourceInterpretDialog(wxResourceTable& table, wxExpr *expr,
 #pragma message enable CODCAUUNR
 #endif
 
+#endif // WXWIN_COMPATIBILITY_2_6
+
     dialogItem->SetName(name);
     dialogItem->SetTitle(title);
     dialogItem->SetSize(x, y, width, height);
@@ -2199,8 +2202,10 @@ static wxResourceBitListStruct wxResourceBitListTable[] =
     { wxT("wxTB_VERTICAL"), wxTB_VERTICAL},
     { wxT("wxTB_FLAT"), wxTB_FLAT},
 
+#if WXWIN_COMPATIBILITY_2_6
     /* wxDialog */
     { wxT("wxDIALOG_MODAL"), wxDIALOG_MODAL },
+#endif // WXWIN_COMPATIBILITY_2_6
 
     /* Generic */
     { wxT("wxVSCROLL"), wxVSCROLL },
@@ -2213,7 +2218,7 @@ static wxResourceBitListStruct wxResourceBitListTable[] =
     { wxT("wxSDI"), 0},
     { wxT("wxMDI_PARENT"), 0},
     { wxT("wxMDI_CHILD"), 0},
-    { wxT("wxTHICK_FRAME"), wxTHICK_FRAME},
+    { wxT("wxTHICK_FRAME"), wxRESIZE_BORDER},
     { wxT("wxRESIZE_BORDER"), wxRESIZE_BORDER},
     { wxT("wxSYSTEM_MENU"), wxSYSTEM_MENU},
     { wxT("wxMINIMIZE_BOX"), wxMINIMIZE_BOX},
@@ -2320,7 +2325,9 @@ static wxResourceBitListStruct wxResourceBitListTable[] =
     { wxT("wxICON_MASK"), wxICON_MASK},
     { wxT("wxCENTRE"), wxCENTRE},
     { wxT("wxCENTER"), wxCENTRE},
+#if WXWIN_COMPATIBILITY_2_6
     { wxT("wxUSER_COLOURS"), wxUSER_COLOURS},
+#endif // WXWIN_COMPATIBILITY_2_6
     { wxT("wxVERTICAL_LABEL"), 0},
     { wxT("wxHORIZONTAL_LABEL"), 0},
 
@@ -3201,7 +3208,13 @@ bool wxLoadFromResource(wxWindow* thisWindow, wxWindow *parent, const wxString&
         if (thisWindow->IsKindOf(CLASSINFO(wxDialog)))
         {
             wxDialog *dialogBox = (wxDialog *)thisWindow;
-            long modalStyle = isModal ? wxDIALOG_MODAL : 0;
+            long modalStyle = isModal ?
+#if WXWIN_COMPATIBILITY_2_6
+                                        wxDIALOG_MODAL
+#else
+                                        0
+#endif // WXWIN_COMPATIBILITY_2_6
+                                      : 0;
             if (!dialogBox->Create(parent, wxID_ANY, title, wxPoint(x, y), wxSize(width, height), theWindowStyle|modalStyle, name))
                 return false;
 
index 4860f849c5fa0e482eb6d2f202b2f9ff3717aee6..4a44fb84c8e72573b472b28e2a88b7a04fb5ceb1 100644 (file)
@@ -153,7 +153,7 @@ wxFprintf(m_wxr,_T("static char *dialog%i = \"dialog(name = '%s',\\\n"),dlgid,dl
 
 //be lazy about style for now. add it later
 
-wxFprintf(m_wxr,_T("style = 'wxRAISED_BORDER | wxCAPTION | wxTHICK_FRAME | wxSYSTEM_MENU',\\\n"));
+wxFprintf(m_wxr,_T("style = 'wxRAISED_BORDER | wxCAPTION | wxRESIZE_BORDER | wxSYSTEM_MENU',\\\n"));
 wxFprintf(m_wxr,_T("id = %i,\\\n"),dlgid);
 
 //Record x,y,width,height
@@ -795,4 +795,3 @@ void rc2wxr::ParseCtrlButton(wxString label, wxString varname)
         wxFprintf(m_wxr,_T("[8, 'wxSWISS', 'wxNORMAL', 'wxNORMAL', 0, 'MS Sans Serif']],\\\n"));
     }
 }
-
index cb5ecc7b3cd589f95872d803a8285ce82354da18..ff46932f3b0fe650ef45f8d2354490b97bfbfe88 100644 (file)
@@ -404,14 +404,16 @@ wxString wxr2xml::GetStyles(wxItemResource * res)
 
     if (restype == _T("wxDialog"))
         {
-        if (style & wxDIALOG_MODAL)
-            s += _T("wxDIALOG_MODAL|");
         if (style & wxDEFAULT_DIALOG_STYLE)
             s += _T("wxDEFAULT_DIALOG_STYLE|");
+#if WXWIN_COMPATIBILITY_2_6
+        if (style & wxDIALOG_MODAL)
+            s += _T("wxDIALOG_MODAL|");
         if (style & wxDIALOG_MODELESS)
             s += _T("wxDIALOG_MODELESS|");
         if (style & wxNO_3D)
             s += _T("wxNO_3D|");
+#endif // WXWIN_COMPATIBILITY_2_6
         if (style & wxTAB_TRAVERSAL)
             s += _T("wxTAB_TRAVERSAL|");
         if (style & wxWS_EX_VALIDATE_RECURSIVELY)
@@ -420,8 +422,8 @@ wxString wxr2xml::GetStyles(wxItemResource * res)
             s += _T("wxSTAY_ON_TOP|");
         if (style & wxCAPTION)
             s += _T("wxCAPTION|");
-        if (style & wxTHICK_FRAME)
-            s += _T("wxTHICK_FRAME|");
+        if (style & wxRESIZE_BORDER)
+            s += _T("wxRESIZE_BORDER|");
         if (style & wxRESIZE_BOX)
             s += _T("wxRESIZE_BOX|");
         if (style & wxRESIZE_BORDER)
@@ -436,8 +438,10 @@ wxString wxr2xml::GetStyles(wxItemResource * res)
         {
         if (style & wxCLIP_CHILDREN)
             s += _T("wxCLIP_CHILDREN|");
+#if WXWIN_COMPATIBILITY_2_6
         if (style & wxNO_3D)
             s += _T("wxNO_3D|");
+#endif // WXWIN_COMPATIBILITY_2_6
         if (style & wxTAB_TRAVERSAL)
             s += _T("wxTAB_TRAVERSAL|");
         if (style & wxWS_EX_VALIDATE_RECURSIVELY)
@@ -536,11 +540,10 @@ wxString wxr2xml::GetStyles(wxItemResource * res)
             s += _T("wxSB_VERTICAL|");
         }
 
-    int l;
-    l = s.Length();
+    int l = s.length();
     // No styles defined
     if (l == 11)
-        return _T("");
+        return wxEmptyString;
     // Trim off last |
     s = s.Truncate(l - 1);
 
@@ -603,7 +606,7 @@ void wxr2xml::ParseMenu(wxItemResource * res)
     m_xmlfile.Write(_T(">\n"));
     m_xmlfile.Write(_T("\t\t\t\t<label>")
         + FixMenuString(res->GetTitle()) + _T("</label>\n"));
-    if (res->GetValue4() != _T(""))
+    if (!res->GetValue4().empty())
         m_xmlfile.Write(_T("\t\t\t\t<help>") + res->GetValue4() +
         _T("</help>\n"));
     // Read in menu items and additional menus
@@ -621,7 +624,7 @@ void wxr2xml::ParseMenu(wxItemResource * res)
 void wxr2xml::ParseMenuItem(wxItemResource * res)
 {
     // Get Menu Item or Separator
-    if (res->GetTitle() == _T("")) {
+    if (res->GetTitle().empty()) {
         m_xmlfile.Write(_T("\t\t\t<object class=\"separator\"/>\n"));
     } else {
         m_xmlfile.Write(_T("\t\t\t\t<object class=\"wxMenuItem\" "));
@@ -631,7 +634,7 @@ void wxr2xml::ParseMenuItem(wxItemResource * res)
         m_xmlfile.Write(_T(">\n"));
             m_xmlfile.Write(_T("\t\t\t<label>")
             + FixMenuString(res->GetTitle()) + _T("</label>\n"));
-        if (res->GetValue4() != _T(""))
+        if (!res->GetValue4().empty())
             m_xmlfile.Write(_T("\t\t\t<help>") +
         res->GetValue4() + _T("</help>\n"));
         if (res->GetValue2())
index c1f4dd4ef7e1300b40d34e34549654926d52ad19..b47f005bd0c6c89f8ca462095c05f477ccb5c22c 100644 (file)
@@ -1,3 +1,14 @@
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%% Name:        tstyles.tex
+%% Purpose:     Window styles documenation
+%% Author:      wxWidgets Team
+%% Modified by:
+%% Created:
+%% RCS-ID:      $Id$
+%% Copyright:   (c) wxWidgets Team
+%% License:     wxWindows license
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 \section{Window styles}\label{windowstyles}
 
 Window styles are used to specify alternative behaviour and appearances for windows, when they are
@@ -5,10 +16,9 @@ created. The symbols are defined in such a way that they can be combined in a `b
 C++ {\it bitwise-or} operator. For example:
 
 \begin{verbatim}
-  wxCAPTION | wxMINIMIZE_BOX | wxMAXIMIZE_BOX | wxTHICK_FRAME
+  wxCAPTION | wxMINIMIZE_BOX | wxMAXIMIZE_BOX | wxRESIZE_BORDER
 \end{verbatim}
 
 For the window styles specific to each window class, please see the documentation
 for the window. Most windows can use the generic styles listed for \helpref{wxWindow}{wxwindow} in
 addition to their own styles.
-
index d5b13e7cc638d027a1d7f2bcf08fbc081a2c3d1c..f0a8f6dda24b820a6a68f66960eeb2110964dcb1 100644 (file)
@@ -4,7 +4,7 @@
 // Author:      David Elliott
 // Modified by:
 // Created:     2002/12/15
-// RCS-ID:      $Id:
+// RCS-ID:      $Id$
 // Copyright:   David Elliott
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
@@ -33,18 +33,19 @@ class WXDLLEXPORT wxDialog : public wxDialogBase, protected wxCocoaNSPanel
 public:
     wxDialog() { Init(); }
 
+#if WXWIN_COMPATIBILITY_2_6
     // Constructor with a modal flag, but no window id - the old convention
     wxDialog(wxWindow *parent,
-            const wxString& title, bool modal,
-            int x = -1, int y= -1, int width = 500, int height = 500,
+            const wxString& title, bool WXUNUSED(modal),
+            int x = wxDefaultCoord, int y= wxDefaultCoord, int width = 500, int height = 500,
             long style = wxDEFAULT_DIALOG_STYLE,
             const wxString& name = wxDialogNameStr)
     {
         Init();
-        long modalStyle = modal ? wxDIALOG_MODAL : wxDIALOG_MODELESS ;
-        Create(parent, -1, title, wxPoint(x, y), wxSize(width, height),
-               style | modalStyle, name);
+        Create(parent, wxID_ANY, title, wxPoint(x, y), wxSize(width, height),
+               style, name);
     }
+#endif // WXWIN_COMPATIBILITY_2_6
 
     // Constructor with no modal flag - the new convention.
     wxDialog(wxWindow *parent, wxWindowID winid,
@@ -87,7 +88,7 @@ public:
     virtual bool IsModal() const { return m_isModal; }
     bool m_isModal;
 
-    // For now, same as Show(TRUE) but returns return code
+    // For now, same as Show(true) but returns return code
     virtual int ShowModal();
 
     // may be called to terminate the dialog with the given return code
index 9fa1cfd9c11ccb7fd7e70abf2d31d62a9d487ddf..be53d0212375eb5af75275019a0d5074adb5f90e 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        dialog.h
+// Name:        wx/motif/dialog.h
 // Purpose:     wxDialog class
 // Author:      Julian Smart
 // Modified by:
@@ -22,7 +22,6 @@ class WXDLLEXPORT wxDialog : public wxDialogBase
 public:
     wxDialog();
 
-    // Constructor with no modal flag - the new convention.
     wxDialog(wxWindow *parent, wxWindowID id,
         const wxString& title,
         const wxPoint& pos = wxDefaultPosition,
@@ -51,7 +50,7 @@ public:
     void SetModal(bool flag);
 
     virtual bool IsModal() const
-    { return ((GetWindowStyleFlag() & wxDIALOG_MODAL) == wxDIALOG_MODAL); }
+    { return m_modalShowing; }
 
     virtual int ShowModal();
     virtual void EndModal(int retCode);
index bace093741a10b2527b15c4602a509bcda0fbb13..ecb99fd9cb2df875c58d4c744bdd5887bf34c8ef 100644 (file)
@@ -44,15 +44,19 @@ class WXDLLEXPORT wxTopLevelWindowBase;
 #define wxTINY_CAPTION_VERT     0x0080
 #define wxRESIZE_BORDER         0x0040
 
-// deprecated versions defined for compatibility reasons
-#define wxRESIZE_BOX            wxMAXIMIZE_BOX
-#define wxTHICK_FRAME           wxRESIZE_BORDER
-
-// obsolete styles, unused any more
-#define wxDIALOG_MODAL          0
-#define wxDIALOG_MODELESS       0
-#define wxNO_3D                 0
-#define wxUSER_COLOURS          0
+#if WXWIN_COMPATIBILITY_2_6
+
+    // deprecated versions defined for compatibility reasons
+    #define wxRESIZE_BOX            wxMAXIMIZE_BOX
+    #define wxTHICK_FRAME           wxRESIZE_BORDER
+
+    // obsolete styles, unused any more
+    #define wxDIALOG_MODAL          0
+    #define wxDIALOG_MODELESS       0
+    #define wxNO_3D                 0
+    #define wxUSER_COLOURS          0
+
+#endif // WXWIN_COMPATIBILITY_2_6
 
 // default style
 //
index 2e78753d0f6591c725d1e01dcc883d304d1b42c4..2372216093ecb8c9e5b4fb64e9a21f842f2d3f6a 100644 (file)
@@ -984,7 +984,7 @@ DnDFrame::DnDFrame(wxFrame *frame, const wxChar *title, int x, int y, int w, int
                                 wxLB_HSCROLL | wxLB_ALWAYS_SB );
 
 #if wxUSE_LOG
-    m_ctrlLog   = new wxTextCtrl(this, wxID_ANY, _T(""), wxDefaultPosition, wxDefaultSize,
+    m_ctrlLog   = new wxTextCtrl(this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize,
                                  wxTE_MULTILINE | wxTE_READONLY |
                                  wxSUNKEN_BORDER );
 
@@ -1160,7 +1160,7 @@ void DnDFrame::OnLogClear(wxCommandEvent& /* event */ )
 void DnDFrame::OnLeftDown(wxMouseEvent &WXUNUSED(event) )
 {
 #if wxUSE_DRAG_AND_DROP
-    if ( !m_strText.IsEmpty() )
+    if ( !m_strText.empty() )
     {
         // start drag operation
         wxTextDataObject textData(m_strText);
@@ -1231,9 +1231,9 @@ void DnDFrame::OnCopyBitmap(wxCommandEvent& WXUNUSED(event))
 {
     // PNG support is not always compiled in under Windows, so use BMP there
 #if wxUSE_LIBPNG
-    wxFileDialog dialog(this, _T("Open a PNG file"), _T(""), _T(""), _T("PNG files (*.png)|*.png"), 0);
+    wxFileDialog dialog(this, _T("Open a PNG file"), wxEmptyString, wxEmptyString, _T("PNG files (*.png)|*.png"), 0);
 #else
-    wxFileDialog dialog(this, _T("Open a BMP file"), _T(""), _T(""), _T("BMP files (*.bmp)|*.bmp"), 0);
+    wxFileDialog dialog(this, _T("Open a BMP file"), wxEmptyString, wxEmptyString, _T("BMP files (*.bmp)|*.bmp"), 0);
 #endif
 
     if (dialog.ShowModal() != wxID_OK)
@@ -1242,7 +1242,7 @@ void DnDFrame::OnCopyBitmap(wxCommandEvent& WXUNUSED(event))
         return;
     }
 
-    if (dialog.GetPath().IsEmpty())
+    if (dialog.GetPath().empty())
     {
         wxLogMessage( _T("Returned empty string.") );
         return;
@@ -1375,7 +1375,7 @@ void DnDFrame::OnPasteMetafile(wxCommandEvent& WXUNUSED(event))
 void DnDFrame::OnCopyFiles(wxCommandEvent& WXUNUSED(event))
 {
 #ifdef __WXMSW__
-    wxFileDialog dialog(this, _T("Select a file to copy"), _T(""), _T(""),
+    wxFileDialog dialog(this, _T("Select a file to copy"), wxEmptyString, wxEmptyString,
                          _T("All files (*.*)|*.*"), 0);
 
     wxArrayString filenames;
@@ -1407,7 +1407,7 @@ void DnDFrame::OnCopyFiles(wxCommandEvent& WXUNUSED(event))
             else
             {
                 wxLogStatus(this, wxT("%d file%s copied to the clipboard"),
-                            count, count == 1 ? wxT("") : wxT("s"));
+                            count, count == 1 ? wxEmptyString : wxEmptyString);
             }
         }
     }
@@ -1509,7 +1509,7 @@ bool DnDFile::OnDropFiles(wxCoord, wxCoord, const wxArrayString& filenames)
 DnDShapeDialog::DnDShapeDialog(wxFrame *parent, DnDShape *shape)
   :wxDialog( parent, 6001, wxT("Choose Shape"), wxPoint( 10, 10 ),
              wxSize( 40, 40 ),
-             wxDEFAULT_DIALOG_STYLE | wxRAISED_BORDER | wxTHICK_FRAME )
+             wxDEFAULT_DIALOG_STYLE | wxRAISED_BORDER | wxRESIZE_BORDER )
 {
     m_shape = shape;
     wxBoxSizer* topSizer = new wxBoxSizer( wxVERTICAL );
index cccad7529ba8fb0d503ceaf5acbba27d9516b2b5..c3aa8379507fe9384c664e481708342a802069ed 100644 (file)
@@ -80,16 +80,6 @@ events. Windows only.
 </TD></TR>
 
 
-<TR><TD VALIGN=TOP>
-<B>wxNO_3D</B>
-</TD>
-
-<TD VALIGN=TOP>
-Prevents the children of this window taking on 3D styles, even though
-the application-wide policy is for 3D controls. Windows only.
-</TD></TR>
-
-
 <TR><TD VALIGN=TOP>
 <B>wxTAB_TRAVERSAL</B>
 </TD>
index f010b2fa67c357882edeb9977d011ffcfa35263a..4d527e1555d6fbe26042fbe9d9f8d49fefdb97b1 100644 (file)
@@ -39,7 +39,7 @@ wxInfoFrame::wxInfoFrame(wxWindow *parent, const wxString& message)
            : wxFrame(parent, wxID_ANY, wxT("Busy"),
                      wxDefaultPosition, wxDefaultSize,
 #if defined(__WXX11__)
-                     wxTHICK_FRAME
+                     wxRESIZE_BORDER
 #else
                      wxSIMPLE_BORDER
 #endif
index fae5ccd21f3bc5311956915c9584eba73078e3c1..f4f89178bd4806cfc13b923caa9102e4ad8e966f 100644 (file)
@@ -296,7 +296,7 @@ wxDebugReportDialog::wxDebugReportDialog(wxDebugReport& dbgrpt)
                               dbgrpt.GetReportName().c_str()),
                               wxDefaultPosition,
                               wxDefaultSize,
-                              wxDEFAULT_DIALOG_STYLE | wxTHICK_FRAME),
+                              wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER),
                      m_dbgrpt(dbgrpt)
 {
     // upper part of the dialog: explanatory message
index bc1d4d2eb4922a54027a2d5286f43421eaece76f..5abada8309e3f4776aea76a34f7372364a1ffdd8 100644 (file)
@@ -83,7 +83,7 @@ wxTextEntryDialog::wxTextEntryDialog(wxWindow *parent,
                                      long style,
                                      const wxPoint& pos)
                  : wxDialog(parent, wxID_ANY, caption, pos, wxDefaultSize,
-                            wxDEFAULT_DIALOG_STYLE | wxDIALOG_MODAL),
+                            wxDEFAULT_DIALOG_STYLE),
                    m_value(value)
 {
     m_dialogStyle = style;
index cc38234f56bea14c3cd8776791559d5446a68396..70b227ac59f36748b6f37b08f6db9f37def3c497 100644 (file)
@@ -69,12 +69,12 @@ extern wxList wxPendingDelete;
 IMPLEMENT_DYNAMIC_CLASS(wxDialog, wxTopLevelWindow)
 
 BEGIN_EVENT_TABLE(wxDialog, wxTopLevelWindow)
-  EVT_BUTTON(wxID_OK, wxDialog::OnOK)
-  EVT_BUTTON(wxID_APPLY, wxDialog::OnApply)
-  EVT_BUTTON(wxID_CANCEL, wxDialog::OnCancel)
-  EVT_CHAR_HOOK(wxDialog::OnCharHook)
-  EVT_SYS_COLOUR_CHANGED(wxDialog::OnSysColourChanged)
-  EVT_CLOSE(wxDialog::OnCloseWindow)
+    EVT_BUTTON(wxID_OK, wxDialog::OnOK)
+    EVT_BUTTON(wxID_APPLY, wxDialog::OnApply)
+    EVT_BUTTON(wxID_CANCEL, wxDialog::OnCancel)
+    EVT_CHAR_HOOK(wxDialog::OnCharHook)
+    EVT_SYS_COLOUR_CHANGED(wxDialog::OnSysColourChanged)
+    EVT_CLOSE(wxDialog::OnCloseWindow)
 END_EVENT_TABLE()
 
 
@@ -319,8 +319,6 @@ bool wxDialog::Show( bool show )
 // Shows a dialog modally, returning a return code
 int wxDialog::ShowModal()
 {
-    m_windowStyle |= wxDIALOG_MODAL;
-
     Show(true);
 
     // after the event loop ran, the widget might already have been destroyed
index bfa9a8a98213aef0c73df90af30cb1cc92e9c487..a51ad28e8b3371dd18ec12367017650f606723a9 100644 (file)
@@ -154,7 +154,7 @@ bool wxTopLevelWindowMotif::Create( wxWindow *parent, wxWindowID id,
             ( m_windowStyle & wxTINY_CAPTION_HORIZ ) ||
             ( m_windowStyle & wxTINY_CAPTION_VERT ) )
             decor |= MWM_DECOR_TITLE;
-        if( m_windowStyle & wxTHICK_FRAME )
+        if( m_windowStyle & wxRESIZE_BORDER )
             decor |= MWM_DECOR_BORDER;
         if( m_windowStyle & wxMINIMIZE_BOX )
             decor |= MWM_DECOR_MINIMIZE;
@@ -423,4 +423,3 @@ void wxTLWEventHandler( Widget wid,
 
     *continueToDispatch = True;
 }
-
index ecac0fae545551781f121194f0d79517b463d967..96d9a13b6490e88fb18ed3cac648c066ad0cf940 100644 (file)
@@ -83,10 +83,14 @@ wxBEGIN_FLAGS( wxDialogStyle )
     wxFLAGS_MEMBER(wxWS_EX_VALIDATE_RECURSIVELY)
     wxFLAGS_MEMBER(wxSTAY_ON_TOP)
     wxFLAGS_MEMBER(wxCAPTION)
+#if WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxTHICK_FRAME)
+#endif // WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxSYSTEM_MENU)
     wxFLAGS_MEMBER(wxRESIZE_BORDER)
+#if WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxRESIZE_BOX)
+#endif // WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxCLOSE_BOX)
     wxFLAGS_MEMBER(wxMAXIMIZE_BOX)
     wxFLAGS_MEMBER(wxMINIMIZE_BOX)
@@ -604,4 +608,3 @@ WXLRESULT wxDialog::MSWWindowProc(WXUINT message, WXWPARAM wParam, WXLPARAM lPar
 
     return rc;
 }
-
index 4afd60473737efb67cf40c54f8e8eb70d8872908..1f06b6cefec6f3f79bfd9ccfcdff76bb33f4a56f 100644 (file)
@@ -115,10 +115,14 @@ wxBEGIN_FLAGS( wxFrameStyle )
     // frame styles
     wxFLAGS_MEMBER(wxSTAY_ON_TOP)
     wxFLAGS_MEMBER(wxCAPTION)
+#if WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxTHICK_FRAME)
+#endif // WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxSYSTEM_MENU)
     wxFLAGS_MEMBER(wxRESIZE_BORDER)
+#if WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxRESIZE_BOX)
+#endif // WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxCLOSE_BOX)
     wxFLAGS_MEMBER(wxMAXIMIZE_BOX)
     wxFLAGS_MEMBER(wxMINIMIZE_BOX)
index 96677b643c5b4a380d75a8045e20f44ee2691eaf..63d39498843c7e0d3aede3a8d83e322b3295c25d 100644 (file)
@@ -752,7 +752,7 @@ bool wxMDIChildFrame::Create(wxMDIParentFrame *parent,
     msflags |= WS_MINIMIZEBOX;
   if (style & wxMAXIMIZE_BOX)
     msflags |= WS_MAXIMIZEBOX;
-  if (style & wxTHICK_FRAME)
+  if (style & wxRESIZE_BORDER)
     msflags |= WS_THICKFRAME;
   if (style & wxSYSTEM_MENU)
     msflags |= WS_SYSMENU;
index b001e855687d50fd123c83ac308152da0184ca57..ee3e233a894dbc9f7a898521902df8c7db627a25 100644 (file)
@@ -2043,73 +2043,33 @@ void wxDC::SetBrush(
     }
 } // end of wxDC::SetBrush
 
-void wxDC::SetBackground(
-  const wxBrush&                    rBrush
-)
+void wxDC::SetBackground(const wxBrush& rBrush)
 {
     m_backgroundBrush = rBrush;
-    if (!m_backgroundBrush.Ok())
-        return;
-    if (m_pCanvas)
-    {
-        bool                        bCustomColours = true;
 
-        //
-        // If we haven't specified wxUSER_COLOURS, don't allow the panel/dialog box to
-        // change background colours from the control-panel specified colours.
-        //
-        if (m_pCanvas->IsKindOf(CLASSINFO(wxWindow)) &&
-            ((m_pCanvas->GetWindowStyleFlag() & wxUSER_COLOURS) != wxUSER_COLOURS))
-            bCustomColours = false;
-        if (bCustomColours)
-        {
-            if (m_backgroundBrush.GetStyle()==wxTRANSPARENT)
-            {
-                m_pCanvas->SetTransparent(true);
-            }
-            else
-            {
-                //
-                // Setting the background brush of a DC
-                // doesn't affect the window background colour. However,
-                // I'm leaving in the transparency setting because it's needed by
-                // various controls (e.g. wxStaticText) to determine whether to draw
-                // transparently or not. TODO: maybe this should be a new function
-                // wxWindow::SetTransparency(). Should that apply to the child itself, or the
-                // parent?
-                // m_canvas->SetBackgroundColour(m_backgroundBrush.GetColour());
-                //
-                m_pCanvas->SetTransparent(false);
-            }
-        }
+    if (m_backgroundBrush.Ok())
+    {
+        (void)::GpiSetBackColor((HPS)m_hPS, m_backgroundBrush.GetColour().GetPixel());
     }
-    COLORREF                        vNewColor = m_backgroundBrush.GetColour().GetPixel();
-    (void)::GpiSetBackColor((HPS)m_hPS, (LONG)vNewColor);
 } // end of wxDC::SetBackground
 
-void wxDC::SetBackgroundMode(
-  int                               nMode
-)
+void wxDC::SetBackgroundMode(int nMode)
 {
     m_backgroundMode = nMode;
 } // end of wxDC::SetBackgroundMode
 
-void wxDC::SetLogicalFunction(
-  int                               nFunction
-)
+void wxDC::SetLogicalFunction(int nFunction)
 {
     m_logicalFunction = nFunction;
     SetRop((WXHDC)m_hDC);
 } // wxDC::SetLogicalFunction
 
-void wxDC::SetRop(
-  WXHDC                             hDC
-)
+void wxDC::SetRop(WXHDC hDC)
 {
     if (!hDC || m_logicalFunction < 0)
         return;
 
-    LONG                            lCRop;
+    LONG lCRop;
     switch (m_logicalFunction)
     {
         case wxXOR:
index 0bd4b9e3881b8963796382fa7844b855f335854c..afa7e6754bb5dce3eae316d3fb34e11affc2f721 100644 (file)
@@ -234,7 +234,7 @@ WXDWORD wxTopLevelWindowOS2::OS2GetStyle(
         lMsflags |= FCF_MINBUTTON;
     if (lStyle & wxMAXIMIZE_BOX)
         lMsflags |= FCF_MAXBUTTON;
-    if (lStyle & wxTHICK_FRAME)
+    if (lStyle & wxRESIZE_BORDER)
         lMsflags |= FCF_DLGBORDER;
     if (lStyle & wxSYSTEM_MENU)
         lMsflags |= FCF_SYSMENU;
@@ -250,7 +250,7 @@ WXDWORD wxTopLevelWindowOS2::OS2GetStyle(
     if (lStyle & wxTINY_CAPTION_HORIZ)
         lMsflags |= FCF_TASKLIST;
 
-    if ((lStyle & wxTHICK_FRAME) == 0)
+    if ((lStyle & wxRESIZE_BORDER) == 0)
         lMsflags |= FCF_BORDER;
     if (lStyle & wxFRAME_TOOL_WINDOW)
         *pdwExflags = kFrameToolWindow;
index b3a78a9c5f88867e5b613112c36db426ab2000f2..4538f533ec0d61e10599ea3a64d5a2356406f8ee 100644 (file)
@@ -71,10 +71,14 @@ wxBEGIN_FLAGS( wxDialogStyle )
     wxFLAGS_MEMBER(wxWS_EX_VALIDATE_RECURSIVELY)
     wxFLAGS_MEMBER(wxSTAY_ON_TOP)
     wxFLAGS_MEMBER(wxCAPTION)
+#if WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxTHICK_FRAME)
+#endif // WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxSYSTEM_MENU)
     wxFLAGS_MEMBER(wxRESIZE_BORDER)
+#if WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxRESIZE_BOX)
+#endif // WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxCLOSE_BOX)
     wxFLAGS_MEMBER(wxMAXIMIZE_BOX)
     wxFLAGS_MEMBER(wxMINIMIZE_BOX)
index efdaf784f20de51df30c1784b08c722fb72b784c..c660adb68e2d1b815d8988ccf624fd668b93bf95 100644 (file)
@@ -106,10 +106,14 @@ wxBEGIN_FLAGS( wxFrameStyle )
     // frame styles
     wxFLAGS_MEMBER(wxSTAY_ON_TOP)
     wxFLAGS_MEMBER(wxCAPTION)
+#if WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxTHICK_FRAME)
+#endif // WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxSYSTEM_MENU)
     wxFLAGS_MEMBER(wxRESIZE_BORDER)
+#if WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxRESIZE_BOX)
+#endif // WXWIN_COMPATIBILITY_2_6
     wxFLAGS_MEMBER(wxCLOSE_BOX)
     wxFLAGS_MEMBER(wxMAXIMIZE_BOX)
     wxFLAGS_MEMBER(wxMINIMIZE_BOX)
index 952f36201b773bd3401aef5c032ab521a7027b5e..e14b122ab585849a4fa342c47205aeec45d32170 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        topluniv.cpp
+// Name:        src/univ/topluniv.cpp
 // Author:      Vaclav Slavik
 // Id:          $Id$
 // Copyright:   (c) 2001-2002 SciTech Software, Inc. (www.scitechsoft.com)
@@ -21,8 +21,6 @@
 #pragma hdrstop
 #endif
 
-#include "wx/defs.h"
-
 #ifndef WX_PRECOMP
     #include "wx/dcclient.h"
     #include "wx/settings.h"
@@ -76,8 +74,8 @@ bool wxTopLevelWindow::Create(wxWindow *parent,
 
     if ( ms_drawDecorations == -1 )
     {
-        ms_drawDecorations = 
-            !wxSystemSettings::HasFeature(wxSYS_CAN_DRAW_FRAME_DECORATIONS) 
+        ms_drawDecorations =
+            !wxSystemSettings::HasFeature(wxSYS_CAN_DRAW_FRAME_DECORATIONS)
             || wxGetEnv(wxT("WXDECOR"), NULL);
         // FIXME -- wxUniv should provide a way to force non-native decorations!
         //          $WXDECOR is just a hack in absence of better wxUniv solution
@@ -96,7 +94,7 @@ bool wxTopLevelWindow::Create(wxWindow *parent,
         exstyleOrig = GetExtraStyle();
         style &= ~(wxCAPTION | wxMINIMIZE_BOX | wxMAXIMIZE_BOX |
                    wxSYSTEM_MENU | wxRESIZE_BORDER | wxFRAME_TOOL_WINDOW |
-                   wxTHICK_FRAME);
+                   wxRESIZE_BORDER);
         style |= wxSIMPLE_BORDER;
         SetExtraStyle(exstyleOrig &
                       ~(wxFRAME_EX_CONTEXTHELP | wxDIALOG_EX_CONTEXTHELP));
@@ -161,7 +159,7 @@ long wxTopLevelWindow::GetDecorationsStyle() const
     }
     if ( (m_windowStyle & (wxSIMPLE_BORDER | wxNO_BORDER)) == 0 )
         style |= wxTOPLEVEL_BORDER;
-    if ( m_windowStyle & (wxRESIZE_BORDER | wxTHICK_FRAME) )
+    if ( m_windowStyle & (wxRESIZE_BORDER | wxRESIZE_BORDER) )
         style |= wxTOPLEVEL_RESIZEABLE;
 
     if ( IsMaximized() )
@@ -350,14 +348,10 @@ static bool wxGetResizingCursor(long hitTestResult, wxCursor& cursor)
                 break;
             default:
                 return false;
-                #if 0
-                // not rachable due to earlier return
-                break;
-                #endif
         }
         return true;
     }
-    
+
     return false;
 }
 
@@ -381,7 +375,7 @@ class wxInteractiveMoveHandler : public wxEvtHandler
 {
 public:
     wxInteractiveMoveHandler(wxInteractiveMoveData& data) : m_data(data) {}
-    
+
 private:
     DECLARE_EVENT_TABLE()
     void OnMouseMove(wxMouseEvent& event);
@@ -400,7 +394,7 @@ BEGIN_EVENT_TABLE(wxInteractiveMoveHandler, wxEvtHandler)
 END_EVENT_TABLE()
 
 
-static inline LINKAGEMODE 
+static inline LINKAGEMODE
 void wxApplyResize(wxInteractiveMoveData& data, const wxPoint& diff)
 {
     if ( data.m_flags & wxINTERACTIVE_RESIZE_W )
@@ -421,7 +415,7 @@ void wxApplyResize(wxInteractiveMoveData& data, const wxPoint& diff)
     {
         data.m_rect.height += diff.y;
     }
-    
+
     if ( data.m_minSize.x != wxDefaultCoord && data.m_rect.width < data.m_minSize.x )
     {
         if ( data.m_flags & wxINTERACTIVE_RESIZE_W )
@@ -481,7 +475,7 @@ void wxInteractiveMoveHandler::OnMouseDown(wxMouseEvent& WXUNUSED(event))
 void wxInteractiveMoveHandler::OnKeyDown(wxKeyEvent& event)
 {
     wxPoint diff(wxDefaultCoord,wxDefaultCoord);
-    
+
     switch ( event.GetKeyCode() )
     {
         case WXK_UP:    diff = wxPoint(0, -16); break;
@@ -496,7 +490,7 @@ void wxInteractiveMoveHandler::OnKeyDown(wxKeyEvent& event)
             m_data.m_evtLoop->Exit();
             return;
     }
-    
+
     if ( diff.x != wxDefaultCoord )
     {
         if ( m_data.m_flags & wxINTERACTIVE_WAIT_FOR_INPUT )
@@ -510,14 +504,14 @@ void wxInteractiveMoveHandler::OnKeyDown(wxKeyEvent& event)
 
             if ( m_data.m_flags & wxINTERACTIVE_MOVE )
             {
-                m_data.m_pos = m_data.m_window->GetPosition() + 
+                m_data.m_pos = m_data.m_window->GetPosition() +
                                wxPoint(m_data.m_window->GetSize().x/2, 8);
             }
         }
 
         wxPoint warp;
         bool changeCur = false;
-        
+
         if ( m_data.m_flags & wxINTERACTIVE_MOVE )
         {
             m_data.m_rect.Offset(diff);
@@ -526,7 +520,7 @@ void wxInteractiveMoveHandler::OnKeyDown(wxKeyEvent& event)
         }
         else /* wxINTERACTIVE_RESIZE */
         {
-            if ( !(m_data.m_flags & 
+            if ( !(m_data.m_flags &
                   (wxINTERACTIVE_RESIZE_N | wxINTERACTIVE_RESIZE_S)) )
             {
                 if ( diff.y < 0 )
@@ -543,7 +537,7 @@ void wxInteractiveMoveHandler::OnKeyDown(wxKeyEvent& event)
                     changeCur = true;
                 }
             }
-            if ( !(m_data.m_flags & 
+            if ( !(m_data.m_flags &
                   (wxINTERACTIVE_RESIZE_W | wxINTERACTIVE_RESIZE_E)) )
             {
                 if ( diff.x < 0 )
@@ -608,17 +602,17 @@ void wxTopLevelWindow::InteractiveMove(int flags)
     wxASSERT_MSG( !((flags & wxINTERACTIVE_MOVE) && (flags & wxINTERACTIVE_RESIZE)),
                   wxT("can't move and resize window at the same time") );
 
-    wxASSERT_MSG( !(flags & wxINTERACTIVE_RESIZE) || 
-                  (flags & wxINTERACTIVE_WAIT_FOR_INPUT) || 
+    wxASSERT_MSG( !(flags & wxINTERACTIVE_RESIZE) ||
+                  (flags & wxINTERACTIVE_WAIT_FOR_INPUT) ||
                   (flags & wxINTERACTIVE_RESIZE_DIR),
                   wxT("direction of resizing not specified") );
 
     wxInteractiveMoveData data;
     wxEventLoop loop;
-    
+
     SetFocus();
 
-#ifndef __WXGTK__    
+#ifndef __WXGTK__
     if ( flags & wxINTERACTIVE_WAIT_FOR_INPUT )
     {
         wxCursor sizingCursor(wxCURSOR_SIZING);
@@ -754,7 +748,7 @@ bool wxTopLevelWindow::PerformAction(const wxControlAction& action,
 void wxTopLevelWindow::OnSystemMenu(wxCommandEvent& event)
 {
     bool ret = true;
-    
+
     switch (event.GetId())
     {
         case wxID_CLOSE_FRAME:
@@ -783,7 +777,7 @@ void wxTopLevelWindow::OnSystemMenu(wxCommandEvent& event)
         default:
             ret = false;
     }
-    
+
     if ( !ret )
         event.Skip();
 }
index eae804059de8a18612b624e26c02efab79132a5f..89d0f13189e4931f4c4f06a53ce4026a69b61442 100644 (file)
@@ -696,10 +696,10 @@ bool wxSetWMDecorations(Window w, long style)
         // The default dialog style doesn't include any kind
         // of border, which is a bit odd. Anyway, inclusion
         // of a caption surely implies a border.
-        style |= wxTHICK_FRAME;
+        style |= wxRESIZE_BORDER;
     }
 
-    if (style & wxTHICK_FRAME)
+    if (style & wxRESIZE_BORDER)
     {
         wmProp.props |= GR_WM_PROPS_APPFRAME ;
         wmProp.flags |= GR_WM_FLAGS_PROPS ;
@@ -721,7 +721,7 @@ bool wxSetWMDecorations(Window w, long style)
         wmProp.flags |= GR_WM_FLAGS_PROPS ;
     }
 
-    if (((style & wxBORDER) != wxBORDER) && ((style & wxTHICK_FRAME) != wxTHICK_FRAME)
+    if (((style & wxBORDER) != wxBORDER) && ((style & wxRESIZE_BORDER) != wxRESIZE_BORDER)
         && ((style & wxRESIZE_BORDER) != wxRESIZE_BORDER))
     {
         wmProp.props |= GR_WM_PROPS_NODECORATE ;
index 6ebcbaec641229b4381372bb4faea0c51a31e9cf..e7c0c44b8f10ae6717ee0ab537fe041811bdfe59 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        xh_dlg.cpp
+// Name:        src/xrc/xh_dlg.cpp
 // Purpose:     XRC resource for dialogs
 // Author:      Vaclav Slavik
 // Created:     2000/03/05
@@ -30,16 +30,11 @@ wxDialogXmlHandler::wxDialogXmlHandler() : wxXmlResourceHandler()
     XRC_ADD_STYLE(wxSTAY_ON_TOP);
     XRC_ADD_STYLE(wxCAPTION);
     XRC_ADD_STYLE(wxDEFAULT_DIALOG_STYLE);
-    XRC_ADD_STYLE(wxTHICK_FRAME);
     XRC_ADD_STYLE(wxSYSTEM_MENU);
     XRC_ADD_STYLE(wxRESIZE_BORDER);
-    XRC_ADD_STYLE(wxRESIZE_BOX);
     XRC_ADD_STYLE(wxCLOSE_BOX);
-    XRC_ADD_STYLE(wxDIALOG_MODAL);
-    XRC_ADD_STYLE(wxDIALOG_MODELESS);
     XRC_ADD_STYLE(wxDIALOG_NO_PARENT);
 
-    XRC_ADD_STYLE(wxNO_3D);
     XRC_ADD_STYLE(wxTAB_TRAVERSAL);
     XRC_ADD_STYLE(wxWS_EX_VALIDATE_RECURSIVELY);
     XRC_ADD_STYLE(wxDIALOG_EX_METAL);
@@ -48,6 +43,14 @@ wxDialogXmlHandler::wxDialogXmlHandler() : wxXmlResourceHandler()
     XRC_ADD_STYLE(wxFRAME_SHAPED);
     XRC_ADD_STYLE(wxDIALOG_EX_CONTEXTHELP);
 
+#if WXWIN_COMPATIBILITY_2_6
+    XRC_ADD_STYLE(wxDIALOG_MODAL);
+    XRC_ADD_STYLE(wxTHICK_FRAME);
+    XRC_ADD_STYLE(wxRESIZE_BOX);
+    XRC_ADD_STYLE(wxDIALOG_MODELESS);
+    XRC_ADD_STYLE(wxNO_3D);
+#endif // WXWIN_COMPATIBILITY_2_6
+
     AddWindowStyles();
 }
 
index 705a3265b6873505d585d045946e6ccaa3154773..d1b7a642270cf89e7936b4ccf1bbd99f5f5cba97 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        xh_frame.cpp
+// Name:        src/xrc/xh_frame.cpp
 // Purpose:     XRC resource for dialogs
 // Author:      Vaclav Slavik & Aleks.
 // Created:     2000/03/05
@@ -31,10 +31,14 @@ wxFrameXmlHandler::wxFrameXmlHandler() : wxXmlResourceHandler()
     XRC_ADD_STYLE(wxCAPTION);
     XRC_ADD_STYLE(wxDEFAULT_DIALOG_STYLE);
     XRC_ADD_STYLE(wxDEFAULT_FRAME_STYLE);
+#if WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxTHICK_FRAME);
+#endif // WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxSYSTEM_MENU);
     XRC_ADD_STYLE(wxRESIZE_BORDER);
+#if WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxRESIZE_BOX);
+#endif // WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxCLOSE_BOX);
 
     XRC_ADD_STYLE(wxFRAME_NO_TASKBAR);
@@ -45,7 +49,9 @@ wxFrameXmlHandler::wxFrameXmlHandler() : wxXmlResourceHandler()
     XRC_ADD_STYLE(wxMINIMIZE_BOX);
     XRC_ADD_STYLE(wxSTAY_ON_TOP);
 
+#if WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxNO_3D);
+#endif // WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxTAB_TRAVERSAL);
     XRC_ADD_STYLE(wxWS_EX_VALIDATE_RECURSIVELY);
     XRC_ADD_STYLE(wxFRAME_EX_METAL);
index 507f49d806fe43ae1dcd680476ee12e534f5ee44..f87e5141c3e4ae0a882a73562ebf918fc7848c8f 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        xh_mdi.cpp
+// Name:        src/xrc/xh_mdi.cpp
 // Purpose:     XRC resource for dialogs
 // Author:      David M. Falkinder & Vaclav Slavik
 // Created:     14/02/2005
@@ -31,10 +31,14 @@ wxMdiXmlHandler::wxMdiXmlHandler() : wxXmlResourceHandler()
     XRC_ADD_STYLE(wxCAPTION);
     XRC_ADD_STYLE(wxDEFAULT_DIALOG_STYLE);
     XRC_ADD_STYLE(wxDEFAULT_FRAME_STYLE);
+#if WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxTHICK_FRAME);
+#endif // WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxSYSTEM_MENU);
     XRC_ADD_STYLE(wxRESIZE_BORDER);
+#if WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxRESIZE_BOX);
+#endif // WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxCLOSE_BOX);
 
     XRC_ADD_STYLE(wxFRAME_NO_TASKBAR);
@@ -45,7 +49,9 @@ wxMdiXmlHandler::wxMdiXmlHandler() : wxXmlResourceHandler()
     XRC_ADD_STYLE(wxMINIMIZE_BOX);
     XRC_ADD_STYLE(wxSTAY_ON_TOP);
 
+#if WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxNO_3D);
+#endif // WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxTAB_TRAVERSAL);
     XRC_ADD_STYLE(wxWS_EX_VALIDATE_RECURSIVELY);
     XRC_ADD_STYLE(wxFRAME_EX_METAL);
index 3ac8987d57afc419fc7d0da9d70eba05de8e8f58..6247d0600c354904404b08f7017297c335a81bca 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        xh_panel.cpp
+// Name:        src/xrc/xh_panel.cpp
 // Purpose:     XRC resource for panels
 // Author:      Vaclav Slavik
 // Created:     2000/03/05
 
 #include "wx/xrc/xh_panel.h"
 #include "wx/panel.h"
-#include "wx/frame.h"  // to get wxNO_3D
+#include "wx/frame.h"
 
 IMPLEMENT_DYNAMIC_CLASS(wxPanelXmlHandler, wxXmlResourceHandler)
 
 wxPanelXmlHandler::wxPanelXmlHandler() : wxXmlResourceHandler()
 {
+#if WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxNO_3D);
+#endif // WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxTAB_TRAVERSAL);
     XRC_ADD_STYLE(wxWS_EX_VALIDATE_RECURSIVELY);
-    
+
     AddWindowStyles();
 }
 
index e99190c020d6af382844e25fa9edf19ef842a483..59988f784427e24069114d54d8fa80f23bac67f6 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        xh_scwin.cpp
+// Name:        src/xrc/xh_scwin.cpp
 // Purpose:     XRC resource for wxScrolledWindow
 // Author:      Vaclav Slavik
 // Created:     2002/10/18
@@ -19,7 +19,7 @@
 
 #include "wx/xrc/xh_scwin.h"
 #include "wx/scrolwin.h"
-#include "wx/frame.h"  // to get wxNO_3D
+#include "wx/frame.h"
 
 IMPLEMENT_DYNAMIC_CLASS(wxScrolledWindowXmlHandler, wxXmlResourceHandler)
 
@@ -30,7 +30,9 @@ wxScrolledWindowXmlHandler::wxScrolledWindowXmlHandler()
     XRC_ADD_STYLE(wxVSCROLL);
 
     // wxPanel styles
+#if WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxNO_3D);
+#endif // WXWIN_COMPATIBILITY_2_6
     XRC_ADD_STYLE(wxTAB_TRAVERSAL);
     XRC_ADD_STYLE(wxWS_EX_VALIDATE_RECURSIVELY);
 
index 91dea16977095c0c04bbfb55d4ba51f28a777aa7..3d059fbf443726c59a30eb0ec719c75addac31a1 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        xh_sizer.cpp
+// Name:        src/xrc/xh_sizer.cpp
 // Purpose:     XRC resource for wxBoxSizer
 // Author:      Vaclav Slavik
 // Created:     2000/03/21
@@ -235,7 +235,7 @@ wxObject* wxSizerXmlHandler::Handle_sizer()
             sizer->Fit(m_parentAsWindow);
         m_node = nd;
 
-        if (m_parentAsWindow->GetWindowStyle() & (wxRESIZE_BOX | wxRESIZE_BORDER))
+        if (m_parentAsWindow->GetWindowStyle() & (wxMAXIMIZE_BOX | wxRESIZE_BORDER))
             sizer->SetSizeHints(m_parentAsWindow);
     }