Update of /cvsroot/mahogany/M/src/modules
In directory sc8-pr-cvs1:/tmp/cvs-serv7872/src/modules

Modified Files:
        HtmlViewer.cpp LayoutEditor.cpp LayoutViewer.cpp 
        TextViewer.cpp 
Log Message:
compilation fixes for wxCocoa (no wxUSE_TOOLTIPS nor wxUSE_PRINTING_ARCHITECTURE)

Index: HtmlViewer.cpp
===================================================================
RCS file: /cvsroot/mahogany/M/src/modules/HtmlViewer.cpp,v
retrieving revision 1.58
retrieving revision 1.59
diff -b -u -2 -r1.58 -r1.59
--- HtmlViewer.cpp      6 Jan 2004 00:37:09 -0000       1.58
+++ HtmlViewer.cpp      10 Jan 2004 18:49:24 -0000      1.59
@@ -176,6 +176,8 @@
    bool m_hasGlobalFont;
 
+#if wxUSE_PRINTING_ARCHITECTURE
    // the object which does all printing for us
    wxHtmlEasyPrinting *m_printHtml;
+#endif // wxUSE_PRINTING_ARCHITECTURE
 
    DECLARE_MESSAGE_VIEWER()
@@ -575,5 +577,7 @@
    m_nImage = 0;
 
+#if wxUSE_PRINTING_ARCHITECTURE
    m_printHtml = NULL;
+#endif // wxUSE_PRINTING_ARCHITECTURE
 
    m_htmlText.reserve(4096);
@@ -584,5 +588,7 @@
    FreeMemoryFS();
 
+#if wxUSE_PRINTING_ARCHITECTURE
    delete m_printHtml;
+#endif // wxUSE_PRINTING_ARCHITECTURE
 }
 
@@ -663,4 +669,5 @@
 void HtmlViewer::InitPrinting()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    if ( !m_printHtml )
    {
@@ -673,18 +680,25 @@
    *m_printHtml->GetPrintData() = *app->GetPrintData();
    *m_printHtml->GetPageSetupData() = *app->GetPageSetupData();
+#endif // wxUSE_PRINTING_ARCHITECTURE
 }
 
 bool HtmlViewer::Print()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    InitPrinting();
 
    return m_printHtml->PrintText(m_htmlText);
+#else // !wxUSE_PRINTING_ARCHITECTURE
+   return false;
+#endif // wxUSE_PRINTING_ARCHITECTURE/!wxUSE_PRINTING_ARCHITECTURE
 }
 
 void HtmlViewer::PrintPreview()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    InitPrinting();
 
    (void)m_printHtml->PreviewText(m_htmlText);
+#endif // wxUSE_PRINTING_ARCHITECTURE
 }
 

Index: LayoutEditor.cpp
===================================================================
RCS file: /cvsroot/mahogany/M/src/modules/LayoutEditor.cpp,v
retrieving revision 1.19
retrieving revision 1.20
diff -b -u -2 -r1.19 -r1.20
--- LayoutEditor.cpp    13 Oct 2003 00:41:13 -0000      1.19
+++ LayoutEditor.cpp    10 Jan 2004 18:49:24 -0000      1.20
@@ -27,4 +27,6 @@
 #   include "Mcommon.h"
 #   include "Mdefaults.h"
+
+#   include <wx/frame.h>
 #endif // USE_PCH
 
@@ -457,11 +459,17 @@
 bool LayoutEditor::Print()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    return wxLayoutPrintout::Print(m_LayoutWindow,
                                   m_LayoutWindow->GetLayoutList());
+#else // !wxUSE_PRINTING_ARCHITECTURE
+   return false;
+#endif // wxUSE_PRINTING_ARCHITECTURE/!wxUSE_PRINTING_ARCHITECTURE
 }
 
 void LayoutEditor::PrintPreview()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    (void)wxLayoutPrintout::PrintPreview(m_LayoutWindow->GetLayoutList());
+#endif // wxUSE_PRINTING_ARCHITECTURE
 }
 

Index: LayoutViewer.cpp
===================================================================
RCS file: /cvsroot/mahogany/M/src/modules/LayoutViewer.cpp,v
retrieving revision 1.35
retrieving revision 1.36
diff -b -u -2 -r1.35 -r1.36
--- LayoutViewer.cpp    18 Dec 2003 20:39:05 -0000      1.35
+++ LayoutViewer.cpp    10 Jan 2004 18:49:24 -0000      1.36
@@ -406,10 +406,16 @@
 bool LayoutViewer::Print()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    return wxLayoutPrintout::Print(m_window, m_window->GetLayoutList());
+#else // !wxUSE_PRINTING_ARCHITECTURE
+   return false;
+#endif // wxUSE_PRINTING_ARCHITECTURE/!wxUSE_PRINTING_ARCHITECTURE
 }
 
 void LayoutViewer::PrintPreview()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    (void)wxLayoutPrintout::PrintPreview(m_window->GetLayoutList());
+#endif // wxUSE_PRINTING_ARCHITECTURE
 }
 

Index: TextViewer.cpp
===================================================================
RCS file: /cvsroot/mahogany/M/src/modules/TextViewer.cpp,v
retrieving revision 1.54
retrieving revision 1.55
diff -b -u -2 -r1.54 -r1.55
--- TextViewer.cpp      18 Dec 2003 20:39:05 -0000      1.54
+++ TextViewer.cpp      10 Jan 2004 18:49:24 -0000      1.55
@@ -51,4 +51,6 @@
 class TextViewerWindow;
 
+#if wxUSE_PRINTING_ARCHITECTURE
+
 // ----------------------------------------------------------------------------
 // wxTextEasyPrinting: easy way to print text (TODO: move to wxWindows)
@@ -68,4 +70,6 @@
 };
 
+#endif // wxUSE_PRINTING_ARCHITECTURE
+
 // ----------------------------------------------------------------------------
 // TextViewer: a wxTextCtrl-based MessageViewer implementation
@@ -145,7 +149,4 @@
    TextViewerWindow *m_window;
 
-   // the object which does the printing
-   wxTextEasyPrinting *m_printText;
-
    // the position of the last match used by Find() and FindAgain()
    long m_posFind;
@@ -154,4 +155,9 @@
    wxString m_textFind;
 
+#if wxUSE_PRINTING_ARCHITECTURE
+   // the object which does the printing
+   wxTextEasyPrinting *m_printText;
+#endif // wxUSE_PRINTING_ARCHITECTURE
+
    DECLARE_MESSAGE_VIEWER()
 };
@@ -233,4 +239,6 @@
 };
 
+#if wxUSE_PRINTING_ARCHITECTURE
+
 // ============================================================================
 // wxTextEasyPrinting implementation
@@ -329,4 +337,6 @@
 }
 
+#endif // wxUSE_PRINTING_ARCHITECTURE
+
 // ============================================================================
 // TextViewerWindow implementation
@@ -511,6 +521,9 @@
 {
    m_window = NULL;
-   m_printText = NULL;
    m_posFind = -1;
+
+#if wxUSE_PRINTING_ARCHITECTURE
+   m_printText = NULL;
+#endif // wxUSE_PRINTING_ARCHITECTURE
 }
 
@@ -610,4 +623,5 @@
 void TextViewer::InitPrinting()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    if ( !m_printText )
    {
@@ -620,18 +634,25 @@
    *m_printText->GetPrintData() = *app->GetPrintData();
    *m_printText->GetPageSetupData() = *app->GetPageSetupData();
+#endif // wxUSE_PRINTING_ARCHITECTURE
 }
 
 bool TextViewer::Print()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    InitPrinting();
 
    return m_printText->Print(m_window);
+#else // !wxUSE_PRINTING_ARCHITECTURE
+   return false;
+#endif // wxUSE_PRINTING_ARCHITECTURE/!wxUSE_PRINTING_ARCHITECTURE
 }
 
 void TextViewer::PrintPreview()
 {
+#if wxUSE_PRINTING_ARCHITECTURE
    InitPrinting();
 
    (void)m_printText->Preview(m_window);
+#endif // wxUSE_PRINTING_ARCHITECTURE
 }
 



-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_______________________________________________
Mahogany-cvsupdates mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates

Reply via email to