]> granicus.if.org Git - handbrake/commitdiff
MacGui: store the job activity log url.
authorDamiano Galassi <damiog@gmail.com>
Thu, 5 Sep 2019 11:20:29 +0000 (13:20 +0200)
committerDamiano Galassi <damiog@gmail.com>
Thu, 5 Sep 2019 11:20:29 +0000 (13:20 +0200)
macosx/HBQueue.m
macosx/HBQueueItem.h
macosx/HBQueueItem.m

index 0d812b1d8381ea07b608568c0359d45ef8b1dafd..5046b12bed1b773ade93a35346fc76899678da18 100644 (file)
@@ -606,6 +606,8 @@ NSString * const HBQueueItemNotificationItemKey = @"HBQueueItemNotificationItemK
             self.currentLog = [[HBJobOutputFileWriter alloc] initWithJob:nextItem.job];
             if (self.currentLog)
             {
+                nextItem.activityLogURL = self.currentLog.url;
+
                 dispatch_queue_t mainQueue = dispatch_get_main_queue();
                 [self.core.stderrRedirect addListener:self.currentLog queue:mainQueue];
                 [self.core.stdoutRedirect addListener:self.currentLog queue:mainQueue];
index ddcf1b6a59f12469cb82a4f9f174b440c77b4ae9..3efdff4667436ad26890ec40f6a093e5b6f8137b 100644 (file)
@@ -30,12 +30,12 @@ typedef NS_ENUM(NSUInteger, HBQueueItemState) {
 @property (nonatomic, readonly) HBJob *job;
 
 /// Current state of the job.
-@property (nonatomic, readwrite) HBQueueItemState state;
+@property (nonatomic) HBQueueItemState state;
 
 /// The file URL of the source.
 @property (nonatomic, readonly) NSURL *fileURL;
 
-/// The file URL at which the new file will be created.
+/// The directory URL at which the new file will be created.
 @property (nonatomic, readonly, copy) NSURL *outputURL;
 
 /// The name of the new file that will be created.
@@ -44,6 +44,9 @@ typedef NS_ENUM(NSUInteger, HBQueueItemState) {
 /// The file URL at which the new file will be created.
 @property (nonatomic, readonly, copy) NSURL *completeOutputURL;
 
+/// The file URL at which the new file will be created.
+@property (nonatomic, copy, nullable) NSURL *activityLogURL;
+
 @property (nonatomic) NSTimeInterval encodeDuration;
 @property (nonatomic) NSTimeInterval pauseDuration;
 
index 29aef3530de874a84fc2f2ca095c4e933be69ab0..8e5b60aff3a555df174e1cbcd428a129a5ffc5e9 100644 (file)
@@ -233,6 +233,8 @@ static NSString *versionKey = @"HBQueueItemVersion";
     encodeObject(_job);
     encodeObject(_uuid);
 
+    encodeObject(_activityLogURL);
+
     encodeDouble(_encodeDuration);
     encodeDouble(_pauseDuration);
 
@@ -252,6 +254,8 @@ static NSString *versionKey = @"HBQueueItemVersion";
         decodeObjectOrFail(_job, HBJob);
         decodeObjectOrFail(_uuid, NSString);
 
+        decodeObject(_activityLogURL, NSURL);
+
         decodeDouble(_encodeDuration);
         decodeDouble(_pauseDuration);