]> git.saurik.com Git - wxWidgets.git/commitdiff
Fixed SetSelection, GetSelection for Portrait/Landscape selection
authorJulian Smart <julian@anthemion.co.uk>
Thu, 18 Jun 1998 14:01:07 +0000 (14:01 +0000)
committerJulian Smart <julian@anthemion.co.uk>
Thu, 18 Jun 1998 14:01:07 +0000 (14:01 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@112 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/postscrp.cpp

index 9577aae423af2b0210cb95940b91ee433f29f07f..d36e6fa01541f2f007fc175f2eadaa2f24b7f77f 100644 (file)
@@ -2065,7 +2065,7 @@ wxDialog(parent, -1, title, pos, size, style)
 
   wxRadioBox *radio0 = new wxRadioBox(this, wxID_PRINTER_ORIENTATION, "Orientation: ", wxPoint(5, yPos), wxSize(-1,-1),
                2,orientation,2,0);
-  radio0->SetSelection((int)wxThePrintSetupData->GetPrinterOrientation());
+  radio0->SetSelection((int)wxThePrintSetupData->GetPrinterOrientation() - 1);
 
   // @@@ Configuration hook
   if (wxThePrintSetupData->GetPrintPreviewCommand() == NULL)
@@ -2144,7 +2144,7 @@ int wxPostScriptPrintDialog::ShowModal (void)
       wxThePrintSetupData->SetPrinterCommand(WXSTRINGCAST text_prt->GetValue ());
 #endif
 
-      wxThePrintSetupData->SetPrinterOrientation((radio0->GetSelection() == PS_LANDSCAPE ? PS_LANDSCAPE : PS_PORTRAIT));
+      wxThePrintSetupData->SetPrinterOrientation((radio0->GetSelection() == 1 ? PS_LANDSCAPE : PS_PORTRAIT));
 
       // C++ wants this
       switch ( radio1->GetSelection() ) {