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

« back to all changes in this revision

Viewing changes to src/DirectoryMonitor.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. 
256
256
            // This *only* retrieves the file ID, which is then used to obtain the in-memory file
257
257
            // information.
258
258
            try {
259
 
                info = file.query_info(FILE_ATTRIBUTE_ID_FILE, UNKNOWN_INFO_FLAGS, cancellable);
 
259
                info = file.query_info(FileAttribute.ID_FILE, UNKNOWN_INFO_FLAGS, cancellable);
260
260
            } catch (Error err) {
261
261
                warning("Unable to query file ID of %s: %s", file.get_path(), err.message);
262
262
                
266
266
            if (!is_file_symlink_supported(info))
267
267
                return null;
268
268
            
269
 
            string? id = info.get_attribute_string(FILE_ATTRIBUTE_ID_FILE);
 
269
            string? id = info.get_attribute_string(FileAttribute.ID_FILE);
270
270
            if (id == null)
271
271
                return null;
272
272
            
284
284
            
285
285
            // get all the interesting matchable items from the supplied FileInfo
286
286
            int64 match_size = match.get_size();
287
 
            TimeVal match_time;
288
 
            match.get_modification_time(out match_time);
 
287
            TimeVal match_time = match.get_modification_time();
289
288
            
290
289
            foreach (File file in map.keys) {
291
290
                FileInfo info = map.get(file);
298
297
                if (match_size != info.get_size())
299
298
                    continue;
300
299
                
301
 
                TimeVal time;
302
 
                info.get_modification_time(out time);
 
300
                TimeVal time = info.get_modification_time();
303
301
                
304
302
                if (time.tv_sec != match_time.tv_sec)
305
303
                    continue;