Return NO in updateMP4FileWithAttributes:attributes:error: only if a serious error happened like a permission error or the mp4 not closing properly. Print the other errors to the log.
This commit is contained in:
1 parent
5219a73a7a
commit
6bc3b03923
2 files changed
+16
-16
No files matched your search
@@ -1,8 +1,8 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="5056" systemVersion="14A299l" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none">
|
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="6254" systemVersion="14C78c" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none">
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<deployment defaultVersion="1060" identifier="macosx"/>
|
<deployment identifier="macosx"/>
|
||||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="5056"/>
|
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="6254"/>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
<objects>
|
<objects>
|
||||||
<customObject id="-2" userLabel="File's Owner" customClass="SBVideoViewController">
|
<customObject id="-2" userLabel="File's Owner" customClass="SBVideoViewController">
|
||||||
@@ -29,7 +29,7 @@
|
|||||||
</connections>
|
</connections>
|
||||||
</customObject>
|
</customObject>
|
||||||
<customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/>
|
<customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/>
|
||||||
<customObject id="-3" userLabel="Application"/>
|
<customObject id="-3" userLabel="Application" customClass="NSObject"/>
|
||||||
<customView id="1">
|
<customView id="1">
|
||||||
<rect key="frame" x="0.0" y="0.0" width="484" height="297"/>
|
<rect key="frame" x="0.0" y="0.0" width="484" height="297"/>
|
||||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
|
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
|
||||||
@@ -87,7 +87,7 @@
|
|||||||
</textFieldCell>
|
</textFieldCell>
|
||||||
</textField>
|
</textField>
|
||||||
<button id="14">
|
<button id="14">
|
||||||
<rect key="frame" x="166" y="178" width="137" height="18"/>
|
<rect key="frame" x="166" y="178" width="150" height="18"/>
|
||||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
|
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
|
||||||
<buttonCell key="cell" type="check" title="Preserve Aspect Ratio" bezelStyle="regularSquare" imagePosition="left" alignment="left" controlSize="small" state="on" inset="2" id="15">
|
<buttonCell key="cell" type="check" title="Preserve Aspect Ratio" bezelStyle="regularSquare" imagePosition="left" alignment="left" controlSize="small" state="on" inset="2" id="15">
|
||||||
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
|
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
|
||||||
|
|||||||
+11
-11
@@ -98,10 +98,10 @@
|
|||||||
if (absoluteURL) {
|
if (absoluteURL) {
|
||||||
self.mp4 = [[[MP42File alloc] initWithExistingFile:absoluteURL andDelegate:self] autorelease];
|
self.mp4 = [[[MP42File alloc] initWithExistingFile:absoluteURL andDelegate:self] autorelease];
|
||||||
|
|
||||||
if (self.mp4) {
|
[fileTracksTable reloadData];
|
||||||
[fileTracksTable reloadData];
|
[self tableViewSelectionDidChange:nil];
|
||||||
[self tableViewSelectionDidChange:nil];
|
|
||||||
} else {
|
if (!self.mp4) {
|
||||||
[self close];
|
[self close];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -144,10 +144,16 @@
|
|||||||
|
|
||||||
- (BOOL)saveDidComplete:(NSError **)outError URL:(NSURL *)absoluteURL
|
- (BOOL)saveDidComplete:(NSError **)outError URL:(NSURL *)absoluteURL
|
||||||
{
|
{
|
||||||
[NSApp endSheet: savingWindow];
|
[NSApp endSheet:savingWindow];
|
||||||
[savingWindow orderOut:self];
|
[savingWindow orderOut:self];
|
||||||
[optBar stopAnimation:self];
|
[optBar stopAnimation:self];
|
||||||
|
|
||||||
|
if (*outError && [*outError code] == 101) {
|
||||||
|
// Write permission error, don't reload the file
|
||||||
|
} else {
|
||||||
|
[self reloadFile:absoluteURL];
|
||||||
|
}
|
||||||
|
|
||||||
if (*outError) {
|
if (*outError) {
|
||||||
[self presentError:*outError
|
[self presentError:*outError
|
||||||
modalForWindow:documentWindow
|
modalForWindow:documentWindow
|
||||||
@@ -158,12 +164,6 @@
|
|||||||
[*outError release];
|
[*outError release];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (*outError && [*outError code] == 101) {
|
|
||||||
// Write persmission error, don't reload the file
|
|
||||||
} else {
|
|
||||||
[self reloadFile:absoluteURL];
|
|
||||||
}
|
|
||||||
|
|
||||||
return YES;
|
return YES;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user