~ubuntu-branches/ubuntu/quantal/shotwell/quantal

« back to all changes in this revision

Viewing changes to src/config/ConfigurationInterfaces.vala

  • Committer: Package Import Robot
  • Author(s): Robert Ancell
  • Date: 2012-02-21 13:52:58 UTC
  • mto: This revision was merged to the branch mainline in revision 47.
  • Revision ID: package-import@ubuntu.com-20120221135258-ao9jiib5qicomq7q
Tags: upstream-0.11.92
ImportĀ upstreamĀ versionĀ 0.11.92

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* Copyright 2009-2011 Yorba Foundation
 
1
/* Copyright 2009-2012 Yorba Foundation
2
2
 *
3
3
 * This software is licensed under the GNU LGPL (version 2.1 or later).
4
4
 * See the COPYING file in this distribution. 
47
47
    LAST_CROP_MENU_CHOICE,
48
48
    LAST_CROP_WIDTH,
49
49
    LAST_USED_SERVICE,
 
50
    LAST_USED_DATAIMPORTS_SERVICE,
50
51
    LIBRARY_PHOTOS_SORT_ASCENDING,
51
52
    LIBRARY_PHOTOS_SORT_BY,
52
53
    LIBRARY_WINDOW_HEIGHT,
160
161
            case LAST_USED_SERVICE:
161
162
                return "LAST_USED_SERVICE";
162
163
                
 
164
            case LAST_USED_DATAIMPORTS_SERVICE:
 
165
                return "LAST_USED_DATAIMPORTS_SERVICE";
 
166
                
163
167
            case LIBRARY_PHOTOS_SORT_ASCENDING:
164
168
                return "LIBRARY_PHOTOS_SORT_ASCENDING";
165
169
                
882
886
    }
883
887
 
884
888
    //
 
889
    // last used import service
 
890
    //
 
891
    public virtual string get_last_used_dataimports_service() {
 
892
        try {
 
893
            return get_engine().get_string_property(ConfigurableProperty.LAST_USED_DATAIMPORTS_SERVICE);
 
894
        } catch (ConfigurationError err) {
 
895
            on_configuration_error(err);
 
896
            // in the event we can't get a reasonable value from the configuration engine, we
 
897
            // return the empty string since it won't match the name of any existing import
 
898
            // service -- this will cause the import subsystem to select the first service
 
899
            // loaded
 
900
            return "";
 
901
        }
 
902
    }
 
903
    
 
904
    public virtual void set_last_used_dataimports_service(string service_name) {
 
905
        try {
 
906
            get_engine().set_string_property(ConfigurableProperty.LAST_USED_DATAIMPORTS_SERVICE, service_name);
 
907
        } catch (ConfigurationError err) {
 
908
            on_configuration_error(err);
 
909
        }
 
910
    }
 
911
 
 
912
    //
885
913
    // library photos sort
886
914
    //
887
915
    public virtual void get_library_photos_sort(out bool sort_order, out int sort_by) {