More swift conversions.
This commit is contained in:
24 files changed
+260
-309
No files matched your search
@@ -1,8 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="11535.1" systemVersion="16B2553a" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none">
|
||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="13528" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none">
|
||||
<dependencies>
|
||||
<deployment identifier="macosx"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="11535.1"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="13528"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<objects>
|
||||
@@ -35,7 +35,7 @@
|
||||
<rect key="frame" x="1" y="0.0" width="446" height="194"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<tableView verticalHuggingPriority="750" allowsExpansionToolTips="YES" columnAutoresizingStyle="lastColumnOnly" alternatingRowBackgroundColors="YES" columnSelection="YES" multipleSelection="NO" autosaveColumns="NO" rowHeight="14" headerView="23" id="22" customClass="SBTableView">
|
||||
<tableView verticalHuggingPriority="750" allowsExpansionToolTips="YES" columnAutoresizingStyle="lastColumnOnly" alternatingRowBackgroundColors="YES" columnSelection="YES" multipleSelection="NO" autosaveColumns="NO" rowHeight="14" headerView="23" id="22" customClass="ExpandedTableView" customModule="Subler" customModuleProvider="target">
|
||||
<rect key="frame" x="0.0" y="0.0" width="446" height="177"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<size key="intercellSpacing" width="3" height="2"/>
|
||||
|
||||
@@ -95,7 +95,7 @@
|
||||
<rect key="frame" x="1" y="0.0" width="446" height="194"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<subviews>
|
||||
<tableView verticalHuggingPriority="750" allowsExpansionToolTips="YES" columnAutoresizingStyle="lastColumnOnly" alternatingRowBackgroundColors="YES" columnReordering="NO" autosaveColumns="NO" typeSelect="NO" rowHeight="14" rowSizeStyle="automatic" headerView="qXU-xB-xRF" viewBased="YES" floatsGroupRows="NO" id="qg5-r0-E4V" customClass="SBTableView">
|
||||
<tableView verticalHuggingPriority="750" allowsExpansionToolTips="YES" columnAutoresizingStyle="lastColumnOnly" alternatingRowBackgroundColors="YES" columnReordering="NO" autosaveColumns="NO" typeSelect="NO" rowHeight="14" rowSizeStyle="automatic" headerView="qXU-xB-xRF" viewBased="YES" floatsGroupRows="NO" id="qg5-r0-E4V" customClass="ExpandedTableView" customModule="Subler" customModuleProvider="target">
|
||||
<rect key="frame" x="0.0" y="0.0" width="446" height="171"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<size key="intercellSpacing" width="3" height="2"/>
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
//
|
||||
|
||||
#import "SBChapterViewController.h"
|
||||
#import "SBTableView.h"
|
||||
#import "Subler-Swift.h"
|
||||
|
||||
#import <MP42Foundation/MP42Utilities.h>
|
||||
|
||||
@@ -15,8 +15,8 @@
|
||||
{
|
||||
NSDictionary *detailBoldAttr;
|
||||
|
||||
IBOutlet SBTableView *chapterTableView;
|
||||
IBOutlet NSButton *removeChapter;
|
||||
IBOutlet ExpandedTableView *chapterTableView;
|
||||
IBOutlet NSButton *removeChapter;
|
||||
}
|
||||
|
||||
- (void)loadView
|
||||
|
||||
@@ -10,7 +10,6 @@ NSString *SublerMetadataPBoardType = @"SublerMetadataPBoardTypeV2";
|
||||
NSString *SublerCoverArtPBoardType = @"SublerCoverArtPBoardType";
|
||||
|
||||
#import "SBMovieViewController.h"
|
||||
#import "SBTableView.h"
|
||||
#import "SBImageBrowserView.h"
|
||||
|
||||
#import <MP42Foundation/MP42Ratings.h>
|
||||
@@ -20,7 +19,7 @@ NSString *SublerCoverArtPBoardType = @"SublerCoverArtPBoardType";
|
||||
|
||||
#import "Subler-Swift.h"
|
||||
|
||||
@interface SBMovieViewController () <NSTableViewDataSource, SBTableViewDelegate, SBImageBrowserViewDelegate>
|
||||
@interface SBMovieViewController () <NSTableViewDataSource, ExpandedTableViewDelegate, SBImageBrowserViewDelegate>
|
||||
|
||||
// Metadata tab
|
||||
@property (nonatomic) NSArray<MP42MetadataItem *> *tags;
|
||||
@@ -39,7 +38,7 @@ NSString *SublerCoverArtPBoardType = @"SublerCoverArtPBoardType";
|
||||
@property (nonatomic, weak) IBOutlet NSPopUpButton *setsPopUp;
|
||||
|
||||
@property (nonatomic, weak) IBOutlet NSButton *removeTagButton;
|
||||
@property (nonatomic, weak) IBOutlet SBTableView *metadataTableView;
|
||||
@property (nonatomic, weak) IBOutlet ExpandedTableView *metadataTableView;
|
||||
|
||||
// Artwork tab
|
||||
@property (nonatomic, weak) IBOutlet NSButton *removeArtworkButton;
|
||||
@@ -691,14 +690,14 @@ static NSArray<NSArray *> *_mediaKinds;
|
||||
}
|
||||
}
|
||||
|
||||
- (void)_deleteSelectionFromTableView:(NSTableView *)tableView;
|
||||
- (void)deleteSelectionIn:(NSTableView *)tableview
|
||||
{
|
||||
[self removeTag:tableView];
|
||||
[self removeTag:tableview];
|
||||
}
|
||||
|
||||
- (void)_copySelectionFromTableView:(NSTableView *)tableView;
|
||||
- (void)copySelectionIn:(NSTableView *)tableview
|
||||
{
|
||||
NSIndexSet *rowIndexes = tableView.selectedRowIndexes;
|
||||
NSIndexSet *rowIndexes = tableview.selectedRowIndexes;
|
||||
NSArray<MP42MetadataItem *> *items = [self.tags objectsAtIndexes:rowIndexes];
|
||||
|
||||
NSMutableString *string = [NSMutableString string];
|
||||
@@ -713,13 +712,13 @@ static NSArray<NSArray *> *_mediaKinds;
|
||||
[pb setData:[NSKeyedArchiver archivedDataWithRootObject:items] forType:SublerMetadataPBoardType];
|
||||
}
|
||||
|
||||
- (void)_cutSelectionFromTableView:(NSTableView *)tableView;
|
||||
- (void)cutSelectionIn:(NSTableView *)tableview
|
||||
{
|
||||
[self _copySelectionFromTableView:tableView];
|
||||
[self removeTag:tableView];
|
||||
[self copySelectionIn:tableview];
|
||||
[self removeTag:tableview];
|
||||
}
|
||||
|
||||
- (void)_pasteToTableView:(NSTableView *)tableView
|
||||
- (void)pasteTo:(NSTableView *)tableview
|
||||
{
|
||||
NSPasteboard *pb = [NSPasteboard generalPasteboard];
|
||||
NSData *archivedData = [pb dataForType:SublerMetadataPBoardType];
|
||||
|
||||
Reference in new issue
Block a user