Made gnome printing stuff return wxPRINT_CANCELLED if

it has been canceled.
  Moved the FORCE_LINK code from app.cpp to the sample
    as I cannot find the right place for it. We'd need
    an empty extrya file for ADV lib only for that.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@31935 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling
2005-02-11 22:16:41 +00:00
parent 67edd0c796
commit 4843cdfe0f
5 changed files with 9 additions and 17 deletions

View File

@@ -50,6 +50,12 @@
#include "mondrian.xpm" #include "mondrian.xpm"
#endif #endif
#if wxUSE_LIBGNOMEPRINT
#include "wx/html/forcelnk.h"
FORCE_LINK(gnome_print)
#endif
// Declare a frame // Declare a frame
MyFrame *frame = (MyFrame *) NULL; MyFrame *frame = (MyFrame *) NULL;
// int orientation = wxPORTRAIT; // int orientation = wxPORTRAIT;
@@ -301,7 +307,7 @@ void MyFrame::Draw(wxDC& dc)
dc.SetBrush(*wxCYAN_BRUSH); dc.SetBrush(*wxCYAN_BRUSH);
dc.SetPen(*wxRED_PEN); dc.SetPen(*wxRED_PEN);
dc.DrawRectangle(0, 30, 200, 100); dc.DrawRoundedRectangle(0, 30, 200, 100, 20);
dc.DrawText( wxT("Rectangle 200 by 100"), 40, 40); dc.DrawText( wxT("Rectangle 200 by 100"), 40, 40);

View File

@@ -80,13 +80,6 @@
#include <gtk/gtk.h> #include <gtk/gtk.h>
#if wxUSE_LIBGNOMEPRINT
#include "wx/html/forcelnk.h"
FORCE_LINK(gnome_print)
#endif
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
// global data // global data
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------

View File

@@ -795,7 +795,7 @@ wxDC* wxGnomePrinter::PrintDialog( wxWindow *parent )
int ret = dialog.ShowModal(); int ret = dialog.ShowModal();
if (ret == wxID_CANCEL) if (ret == wxID_CANCEL)
{ {
sm_lastError = wxPRINTER_ERROR; sm_lastError = wxPRINTER_CANCELLED;
return NULL; return NULL;
} }

View File

@@ -80,13 +80,6 @@
#include <gtk/gtk.h> #include <gtk/gtk.h>
#if wxUSE_LIBGNOMEPRINT
#include "wx/html/forcelnk.h"
FORCE_LINK(gnome_print)
#endif
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
// global data // global data
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------

View File

@@ -795,7 +795,7 @@ wxDC* wxGnomePrinter::PrintDialog( wxWindow *parent )
int ret = dialog.ShowModal(); int ret = dialog.ShowModal();
if (ret == wxID_CANCEL) if (ret == wxID_CANCEL)
{ {
sm_lastError = wxPRINTER_ERROR; sm_lastError = wxPRINTER_CANCELLED;
return NULL; return NULL;
} }