Revision: 7448
          http://mahogany.svn.sourceforge.net/mahogany/?rev=7448&view=rev
Author:   vadz
Date:     2008-05-01 19:03:05 -0700 (Thu, 01 May 2008)

Log Message:
-----------
remove MFolder::SetConfigSourceForWriting(), we really should work at Profile 
level

Modified Paths:
--------------
    trunk/M/include/MFolder.h
    trunk/M/src/classes/MFolder.cpp
    trunk/M/src/gui/wxMFolderDialogs.cpp

Modified: trunk/M/include/MFolder.h
===================================================================
--- trunk/M/include/MFolder.h   2008-05-02 02:01:10 UTC (rev 7447)
+++ trunk/M/include/MFolder.h   2008-05-02 02:03:05 UTC (rev 7448)
@@ -198,13 +198,6 @@
    //@{
 
    /**
-     Set the config source to use for saving changes.
-
-     @sa Profile::SetConfigSourceForWriting().
-    */
-   virtual void SetConfigSourceForWriting(ConfigSource *config) = 0;
-
-   /**
      Get the profile associated with this folder: it will never be NULL (as
      we fall back to the application profile if we don't have our own) and
      can be used to read the other (than the ones we have explicit functions

Modified: trunk/M/src/classes/MFolder.cpp
===================================================================
--- trunk/M/src/classes/MFolder.cpp     2008-05-02 02:01:10 UTC (rev 7447)
+++ trunk/M/src/classes/MFolder.cpp     2008-05-02 02:03:05 UTC (rev 7448)
@@ -192,7 +192,6 @@
    virtual int GetFlags() const { return m_flags; }
    virtual void SetFlags(int flags) { m_flags = flags; }
 
-   virtual void SetConfigSourceForWriting(ConfigSource * /* config */) { }
    virtual Profile *GetProfile() const
    {
       m_profile->IncRef();
@@ -313,11 +312,6 @@
    virtual int GetFlags() const;
    virtual void SetFlags(int flags);
 
-   virtual void SetConfigSourceForWriting(ConfigSource *config)
-   {
-      m_profile->SetConfigSourceForWriting(config);
-   }
-
    virtual Profile *GetProfile() const
    {
       m_profile->IncRef();

Modified: trunk/M/src/gui/wxMFolderDialogs.cpp
===================================================================
--- trunk/M/src/gui/wxMFolderDialogs.cpp        2008-05-02 02:01:10 UTC (rev 
7447)
+++ trunk/M/src/gui/wxMFolderDialogs.cpp        2008-05-02 02:03:05 UTC (rev 
7448)
@@ -2445,8 +2445,11 @@
 
    Profile_obj profileDlg(dlg->GetProfile());
    ConfigSource * const config = profileDlg->GetConfigSourceForWriting();
-   folder->SetConfigSourceForWriting(config);
 
+   Profile_obj profileFolder(folder->GetProfile());
+   CHECK( profileFolder, false, "folder must have profile here" );
+   profileFolder->SetConfigSourceForWriting(config);
+
    // 2nd step: put what we can in MFolder
    folder->SetComment(m_comment->GetValue());
 


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Mahogany-cvsupdates mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates

Reply via email to