Hide the back button on the initial wizard screen.
authorsherscher@apple.com <sherscher@apple.com@214c2c4a-bf3b-4dcf-9390-e4dd3010487d>
Thu, 27 Aug 2009 04:59:19 +0000 (04:59 +0000)
committersherscher@apple.com <sherscher@apple.com@214c2c4a-bf3b-4dcf-9390-e4dd3010487d>
Thu, 27 Aug 2009 04:59:19 +0000 (04:59 +0000)
git-svn-id: http://svn.macosforge.org/repository/mdnsresponder/trunk@6621 214c2c4a-bf3b-4dcf-9390-e4dd3010487d

Clients/PrinterSetupWizard/PrinterSetupWizardSheet.h
Clients/PrinterSetupWizard/SecondPage.cpp

index 9cc5599..e7823b8 100644 (file)
@@ -18,7 +18,6 @@
 #pragma once
 
 
-#include "firstpage.h"
 #include "secondpage.h"
 #include "thirdpage.h"
 #include "fourthpage.h"
@@ -105,7 +104,6 @@ public:
 
 protected:
        DECLARE_MESSAGE_MAP()
-       CFirstPage              m_pgFirst;
        CSecondPage             m_pgSecond;
        CThirdPage              m_pgThird;
        CFourthPage             m_pgFourth;
index cfaa7bf..0499b5b 100644 (file)
@@ -131,6 +131,7 @@ CSecondPage::OnSetActive()
 {
        CPrinterSetupWizardSheet        *       psheet;
        Printer                                         *       printer;
+       CWnd                                            *       pWnd;
        Printers::iterator                              it;
        OSStatus                                                err = kNoErr;
        BOOL                                                    b;
@@ -172,6 +173,13 @@ CSecondPage::OnSetActive()
                ::SetFocus( m_browseList );
        }
 
+       // Hide the back button
+       pWnd = ((CPropertySheet*)GetParent())->GetDlgItem(ID_WIZBACK);\r
+       if ( pWnd != NULL )\r
+       {\r
+               pWnd->ShowWindow(SW_HIDE);\r
+       }
+
 exit:
 
        return b;
@@ -181,13 +189,21 @@ exit:
 BOOL
 CSecondPage::OnKillActive()
 {
-       CPrinterSetupWizardSheet * psheet;
+       CPrinterSetupWizardSheet        * psheet;
+       CWnd                                            * pWnd;
 
        psheet = reinterpret_cast<CPrinterSetupWizardSheet*>(GetParent());
        require_quiet( psheet, exit );   
    
        psheet->SetLastPage(this);
 
+       // Show the back button
+       pWnd = ((CPropertySheet*)GetParent())->GetDlgItem(ID_WIZBACK);\r
+       if ( pWnd != NULL )\r
+       {\r
+               pWnd->ShowWindow(SW_SHOW);\r
+       }
+
 exit:
 
        return CPropertyPage::OnKillActive();