]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/mobile/wxedit/wxedit.cpp
bad link fixed
[wxWidgets.git] / samples / mobile / wxedit / wxedit.cpp
index fe983016ef8108a750ad172ecc6b80d7aafd3f03..c3e155bacebd0a4f8a69ecf6aeadffcd459894a6 100644 (file)
@@ -249,10 +249,7 @@ void MyFrame::OnOpen( wxCommandEvent &event )
 
 void MyFrame::OnSave( wxCommandEvent &event )
 {
-    if (m_filename.empty())
-        OnSaveAs( event );
-    else
-        m_text->SaveFile( m_filename );
+    Save();
 }
 
 void MyFrame::OnSaveAs( wxCommandEvent &event )
@@ -284,7 +281,12 @@ void MyFrame::OnQuit( wxCommandEvent &event )
 
 bool MyFrame::Save()
 {
-   m_text->SaveFile();
+    wxCommandEvent event;
+    
+    if (m_filename.empty())
+        OnSaveAs( event );
+    else
+        m_text->SaveFile( m_filename );
    
    return TRUE;
 }