]> granicus.if.org Git - handbrake/commitdiff
MacGui: remove two old unused classes, remove some old compatibility hacks, and fix...
authorDamiano Galassi <damiog@gmail.com>
Wed, 13 Feb 2019 16:56:02 +0000 (17:56 +0100)
committerDamiano Galassi <damiog@gmail.com>
Wed, 13 Feb 2019 16:56:02 +0000 (17:56 +0100)
16 files changed:
macosx/Base.lproj/MainWindow.xib
macosx/HBAttributedStringAdditions.m
macosx/HBCore.m
macosx/HBDockTextField.h [moved from macosx/DockTextField.h with 86% similarity]
macosx/HBDockTextField.m [moved from macosx/DockTextField.m with 95% similarity]
macosx/HBDockTile.h
macosx/HBDockTile.m
macosx/HBImageAndTextCell.h [deleted file]
macosx/HBImageAndTextCell.m [deleted file]
macosx/HBJob+UIAdditions.h
macosx/HBJob+UIAdditions.m
macosx/HBQueueItem.h
macosx/HBQueueItem.m
macosx/HBTabView.h [deleted file]
macosx/HBTabView.m [deleted file]
macosx/HandBrake.xcodeproj/project.pbxproj

index 9cff4bca50e56e60a736aa6283b55573a752144a..d2d7383e8177727f9bcdd3b4499fd98cee1552c3 100644 (file)
@@ -1,8 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="14460.30.1" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
+<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="14490.59" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
     <dependencies>
         <deployment identifier="macosx"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="14460.30.1"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="14490.59"/>
         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
     </dependencies>
     <objects>
@@ -45,7 +45,7 @@
                 <rect key="frame" x="0.0" y="0.0" width="885" height="600"/>
                 <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
                 <subviews>
-                    <tabView controlSize="small" translatesAutoresizingMaskIntoConstraints="NO" id="1474" customClass="HBTabView">
+                    <tabView controlSize="small" translatesAutoresizingMaskIntoConstraints="NO" id="1474">
                         <rect key="frame" x="13" y="116" width="859" height="382"/>
                         <constraints>
                             <constraint firstAttribute="height" relation="greaterThanOrEqual" constant="334" id="Jdl-tV-liS"/>
@@ -53,7 +53,7 @@
                         <tabViewItems>
                             <tabViewItem label="Summary" identifier="" id="BA0-eg-2Ka">
                                 <view key="view" id="BjX-E2-6tb">
-                                    <rect key="frame" x="10" y="25" width="839" height="344"/>
+                                    <rect key="frame" x="10" y="29" width="839" height="340"/>
                                     <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
                                 </view>
                             </tabViewItem>
@@ -94,9 +94,6 @@
                                 </view>
                             </tabViewItem>
                         </tabViewItems>
-                        <connections>
-                            <outlet property="dropDelegate" destination="-2" id="PXr-K3-L2R"/>
-                        </connections>
                     </tabView>
                     <textField verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" allowsCharacterPickerTouchBarItem="YES" preferredMaxLayoutWidth="100" translatesAutoresizingMaskIntoConstraints="NO" id="1538">
                         <rect key="frame" x="18" y="570" width="48" height="14"/>
index 1f16a95680a80c218fc64f1969034ec0548ced72..12b9c8b4f7c10dac78491c26b65122c2423fb607 100644 (file)
@@ -15,4 +15,4 @@
     [self appendAttributedString:s];
 }
 
-@end
\ No newline at end of file
+@end
index 391153dbba578c4347bdf538b2a445e4a62631f0..40117d4f5f269957e9721767d0e84181c62487a6 100644 (file)
@@ -112,7 +112,7 @@ typedef void (^HBCoreCleanupHandler)(void);
         bzero(_hb_state, sizeof(hb_state_t));
         _logLevel = level;
 
-        _hb_handle = hb_init(level);
+        _hb_handle = hb_init((int)level);
         if (!_hb_handle)
         {
             return nil;
@@ -144,10 +144,10 @@ typedef void (^HBCoreCleanupHandler)(void);
     free(_hb_state);
 }
 
-- (void)setLogLevel:(int)logLevel
+- (void)setLogLevel:(NSInteger)logLevel
 {
     _logLevel = logLevel;
-    hb_log_level_set(_hb_handle, logLevel);
+    hb_log_level_set(_hb_handle, (int)logLevel);
 }
 
 - (void)preventSleep
similarity index 86%
rename from macosx/DockTextField.h
rename to macosx/HBDockTextField.h
index cca7bd074337532d86a3bba1c8127c0acfc81b50..bad413a9cc60762ec40a15e2338133f33b8209c5 100644 (file)
@@ -1,4 +1,4 @@
-/*  DockTextField.h $
+/*  HBDockTextField.h $
  
  This file is part of the HandBrake source code.
  Homepage: <http://handbrake.fr/>.
@@ -6,7 +6,7 @@
 
 #import <Cocoa/Cocoa.h>
 
-@interface DockTextField : NSTextField
+@interface HBDockTextField : NSTextField
 
 @property (nonatomic, copy) NSString *textToDisplay;
 @property (nonatomic, copy) NSColor *startColor;
similarity index 95%
rename from macosx/DockTextField.m
rename to macosx/HBDockTextField.m
index 62a7e337d7bdcf9b55450e2be3e4b883311a7643..25d22b5b3558d6e141e8f40d5b4045d97eb8f818 100644 (file)
@@ -1,15 +1,15 @@
-/*  DockTextField.m $
+/*  HBDockTextField.m $
  
  This file is part of the HandBrake source code.
  Homepage: <http://handbrake.fr/>.
  It may be used under the terms of the GNU General Public License. */
 
-#import "DockTextField.h"
+#import "HBDockTextField.h"
 
 #define DOCK_TEXTFIELD_ALPHA 0.8
 #define DOCK_TEXTFIELD_FONTSIZE 28.0
 
-@interface DockTextField ()
+@interface HBDockTextField ()
 
 @property (nonatomic, readonly) NSDictionary *textAttributes;
 @property (nonatomic, readonly) NSDictionary *smallTextAttributes;
@@ -18,7 +18,7 @@
 
 @end
 
-@implementation DockTextField
+@implementation HBDockTextField
 
 - (instancetype)initWithFrame:(NSRect)frame
 {
index e30e4bbdcdd5dbd31774b83d6aee1540309c316a..434025442d6f07152099398e309e89811a9e9ecc 100644 (file)
@@ -20,7 +20,7 @@
 
 
 /**
- *  Updates two DockTextFields on the dockTile,
+ *  Updates two HBDockTextFields on the dockTile,
  *  one with total percentage, the other one with the ETA.
  *
  *  ETA format is [XX]X:XX:XX when ETA is greater than one hour
index 38a4dda3f57d5da9495b8511120de79cd06bc18b..894f5ca90a1bcfe3efa101b29d20c327ad394de9 100644 (file)
@@ -5,7 +5,7 @@
  It may be used under the terms of the GNU General Public License. */
 
 #import "HBDockTile.h"
-#import "DockTextField.h"
+#import "HBDockTextField.h"
 
 NSString *dockTilePercentFormat = @"%2.1f%%";
 
@@ -13,8 +13,8 @@ NSString *dockTilePercentFormat = @"%2.1f%%";
 
 @property (nonatomic, strong) NSDockTile *dockTile;
 @property (nonatomic, strong) NSImage *image;
-@property (nonatomic, strong) DockTextField * percentField;
-@property (nonatomic, strong) DockTextField * timeField;
+@property (nonatomic, strong) HBDockTextField * percentField;
+@property (nonatomic, strong) HBDockTextField * timeField;
 
 @end
 
@@ -37,11 +37,11 @@ NSString *dockTilePercentFormat = @"%2.1f%%";
         [iv setImage:_image];
         [dockTile setContentView:iv];
 
-        _percentField = [[DockTextField alloc] initWithFrame:NSMakeRect(0.0f, 32.0f, [dockTile size].width, 30.0f)];
+        _percentField = [[HBDockTextField alloc] initWithFrame:NSMakeRect(0.0f, 32.0f, [dockTile size].width, 30.0f)];
         [_percentField changeGradientColors:[NSColor colorWithDeviceRed:0.4f green:0.6f blue:0.4f alpha:1.0f] endColor:[NSColor colorWithDeviceRed:0.2f green:0.4f blue:0.2f alpha:1.0f]];
         [iv addSubview:_percentField];
 
-        _timeField = [[DockTextField alloc] initWithFrame:NSMakeRect(0.0f, 0.0f, [dockTile size].width, 30.0f)];
+        _timeField = [[HBDockTextField alloc] initWithFrame:NSMakeRect(0.0f, 0.0f, [dockTile size].width, 30.0f)];
         [_timeField changeGradientColors:[NSColor colorWithDeviceRed:0.6f green:0.4f blue:0.4f alpha:1.0f] endColor:[NSColor colorWithDeviceRed:0.4f green:0.2f blue:0.2f alpha:1.0f]];
         [iv addSubview:_timeField];
     }
diff --git a/macosx/HBImageAndTextCell.h b/macosx/HBImageAndTextCell.h
deleted file mode 100644 (file)
index 1cebae4..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-/* HBImageAndTextCell
-
-    This file is part of the HandBrake source code.
-    Homepage: <http://handbrake.fr/>.
-    It may be used under the terms of the GNU General Public License.
-*/
-
-#import <Cocoa/Cocoa.h>
-
-@interface HBImageAndTextCell : NSTextFieldCell
-
-@property (strong) NSImage *image;
-@property (nonatomic) NSImageAlignment imageAlignment;
-@property (nonatomic) NSSize imageSpacing;
-
-- (void) drawWithFrame:(NSRect)cellFrame inView:(NSView *)controlView;
-@property (readonly) NSSize cellSize;
-
-@end
diff --git a/macosx/HBImageAndTextCell.m b/macosx/HBImageAndTextCell.m
deleted file mode 100644 (file)
index 5aebf9c..0000000
+++ /dev/null
@@ -1,297 +0,0 @@
-/* HBImageAndTextCell
-
-    This file is part of the HandBrake source code.
-    Homepage: <http://handbrake.fr/>.
-    It may be used under the terms of the GNU General Public License.
-*/
-
-
-#import "HBImageAndTextCell.h"
-
-
-#if 0
-static inline CGFloat
-xLeftInRect(NSSize innerSize, NSRect outerRect)
-{
-  return NSMinX(outerRect);
-}
-
-static inline CGFloat
-xCenterInRect(NSSize innerSize, NSRect outerRect)
-{
-  return MAX(NSMidX(outerRect) - (innerSize.width/2.0), 0.0);
-}
-
-static inline CGFloat
-xRightInRect(NSSize innerSize, NSRect outerRect)
-{
-  return MAX(NSMaxX(outerRect) - innerSize.width, 0.0);
-}
-
-static inline CGFloat
-yTopInRect(NSSize innerSize, NSRect outerRect, BOOL flipped)
-{
-  if (flipped)
-    return NSMinY(outerRect);
-  else
-    return MAX(NSMaxY(outerRect) - innerSize.height, 0.0);
-}
-
-static inline CGFloat
-yCenterInRect(NSSize innerSize, NSRect outerRect, BOOL flipped)
-{
-  return MAX(NSMidY(outerRect) - innerSize.height/2.0, 0.0);
-}
-
-static inline CGFloat
-yBottomInRect(NSSize innerSize, NSRect outerRect, BOOL flipped)
-{
-  if (flipped)
-    return MAX(NSMaxY(outerRect) - innerSize.height, 0.0);
-  else
-    return NSMinY(outerRect);
-}
-
-static inline NSSize
-scaleProportionally(NSSize imageSize, NSRect canvasRect)
-{
-  CGFloat ratio;
-
-  // get the smaller ratio and scale the image size by it
-  ratio = MIN(NSWidth(canvasRect) / imageSize.width,
-             NSHeight(canvasRect) / imageSize.height);
-
-  imageSize.width *= ratio;
-  imageSize.height *= ratio;
-
-  return imageSize;
-}
-
-#endif
-
-@implementation HBImageAndTextCell
-{
-@private
-    NSImage                 *image;
-    NSImageAlignment     imageAlignment;    // defaults to NSImageAlignTop. Supports NSImageAlignCenter & NSImageAlignBottom
-    NSSize               imageSpacing;      // horizontal and vertical spacing around the image
-}
-
--(instancetype)initTextCell:(NSString *)aString
-{
-    if (self = [super initTextCell:aString])
-    {
-        imageAlignment = NSImageAlignTop;
-        imageSpacing = NSMakeSize (3.0, 2.0);
-    }
-    return self; 
-}
-
--(instancetype)initWithCoder:(NSCoder *)decoder
-{
-    if (self = [super initWithCoder:decoder])
-    {
-        imageAlignment = NSImageAlignTop;
-        imageSpacing = NSMakeSize (3.0, 2.0);
-    }
-    return self; 
-}
-
-- copyWithZone:(NSZone *)zone
-{
-    HBImageAndTextCell *cell = (HBImageAndTextCell *)[super copyWithZone:zone];
-    cell->image = image;
-    return cell;
-}
-
-- (void)setImage:(NSImage *)anImage
-{
-    if (anImage != image)
-    {
-        image = anImage;
-    }
-}
-
-- (NSImage *)image
-{
-    return image;
-}
-
-- (void) setImageAlignment:(NSImageAlignment)alignment;
-{
-    imageAlignment = alignment;
-}
-
-- (NSImageAlignment) imageAlignment;
-{
-    return imageAlignment;
-}
-
-- (void)setImageSpacing:(NSSize)aSize;
-{
-    imageSpacing = aSize;
-}
-
-- (NSSize)imageSpacing
-{
-    return imageSpacing;
-}
-
-- (void)editWithFrame:(NSRect)aRect inView:(NSView *)controlView editor:(NSText *)textObj delegate:(id)anObject event:(NSEvent *)theEvent
-{
-    NSRect textFrame, imageFrame;
-    NSDivideRect (aRect, &imageFrame, &textFrame, (imageSpacing.width * 2) + [image size].width, NSMinXEdge);
-    [super editWithFrame: textFrame inView: controlView editor:textObj delegate:anObject event: theEvent];
-}
-
-- (void)selectWithFrame:(NSRect)aRect inView:(NSView *)controlView editor:(NSText *)textObj delegate:(id)anObject start:(NSInteger)selStart length:(NSInteger)selLength
-{
-    NSRect textFrame, imageFrame;
-    NSDivideRect (aRect, &imageFrame, &textFrame, (imageSpacing.width * 2) + [image size].width, NSMinXEdge);
-    [super selectWithFrame: textFrame inView: controlView editor:textObj delegate:anObject start:selStart length:selLength];
-}
-
-- (void)drawWithFrame:(NSRect)cellFrame inView:(NSView *)controlView
-{
-#if 1
-    if (image != nil)
-    {
-        NSSize imageSize;
-        NSRect imageFrame;
-
-        imageSize = [image size];
-        NSDivideRect(cellFrame, &imageFrame, &cellFrame, (imageSpacing.width * 2) + imageSize.width, NSMinXEdge);
-        if ([self drawsBackground])
-        {
-            [[self backgroundColor] set];
-            NSRectFill(imageFrame);
-        }
-        imageFrame.origin.x += imageSpacing.width;
-        imageFrame.size = imageSize;
-
-        switch (imageAlignment)
-        {
-            default:
-            case NSImageAlignTop:
-                if ([controlView isFlipped])
-                    imageFrame.origin.y += imageFrame.size.height;
-                else
-                    imageFrame.origin.y += (cellFrame.size.height - imageFrame.size.height);
-                break;
-
-            case NSImageAlignCenter:
-                if ([controlView isFlipped])
-                    imageFrame.origin.y += ceil((cellFrame.size.height + imageFrame.size.height) / 2);
-                else
-                    imageFrame.origin.y += ceil((cellFrame.size.height - imageFrame.size.height) / 2);
-                break;
-
-             case NSImageAlignBottom:
-                if ([controlView isFlipped])
-                    imageFrame.origin.y += cellFrame.size.height;
-                // for unflipped, imageFrame is already correct
-                break;
-          
-        }
-
-        [image drawAtPoint:imageFrame.origin fromRect:imageFrame operation:NSCompositingOperationSourceOver fraction:1.0];
-    }
-
-    [super drawWithFrame:cellFrame inView:controlView];
-#endif
-
-
-#if 0 // this snippet supports all alignment values plus potentially scaling.
-    if (image != nil)
-    {
-        NSSize imageSize;
-        NSSize srcImageSize;
-        NSRect imageFrame;
-        NSPoint        position;
-        BOOL flipped = [controlView isFlipped];
-
-        imageSize = [image size];
-        srcImageSize = imageSize;   // this will be more useful once/if we support scaling
-        
-        NSDivideRect(cellFrame, &imageFrame, &cellFrame, 12 + imageSize.width, NSMinXEdge);
-        if ([self drawsBackground])
-        {
-            [[self backgroundColor] set];
-            NSRectFill(imageFrame);
-        }
-        
-        switch (imageAlignment)
-        {
-            default:
-            case NSImageAlignLeft:
-                position.x = xLeftInRect(imageSize, imageFrame);
-                position.y = yCenterInRect(imageSize, imageFrame, flipped);
-                break;
-            case NSImageAlignRight:
-                position.x = xRightInRect(imageSize, imageFrame);
-                position.y = yCenterInRect(imageSize, imageFrame, flipped);
-                break;
-            case NSImageAlignCenter:
-                position.x = xCenterInRect(imageSize, imageFrame);
-                position.y = yCenterInRect(imageSize, imageFrame, flipped);
-                break;
-            case NSImageAlignTop:
-                position.x = xCenterInRect(imageSize, imageFrame);
-                position.y = yTopInRect(imageSize, imageFrame, flipped);
-                break;
-            case NSImageAlignBottom:
-                position.x = xCenterInRect(imageSize, imageFrame);
-                position.y = yBottomInRect(imageSize, imageFrame, flipped);
-                break;
-            case NSImageAlignTopLeft:
-                position.x = xLeftInRect(imageSize, imageFrame);
-                position.y = yTopInRect(imageSize, imageFrame, flipped);
-                break;
-            case NSImageAlignTopRight:
-                position.x = xRightInRect(imageSize, imageFrame);
-                position.y = yTopInRect(imageSize, imageFrame, flipped);
-                break;
-            case NSImageAlignBottomLeft:
-                position.x = xLeftInRect(imageSize, imageFrame);
-                position.y = yBottomInRect(imageSize, imageFrame, flipped);
-                break;
-            case NSImageAlignBottomRight:
-                position.x = xRightInRect(imageSize, imageFrame);
-                position.y = yBottomInRect(imageSize, imageFrame, flipped);
-                break;
-        }
-
-        // account for flipped views
-        if (flipped)
-        {
-            position.y += imageSize.height;
-            imageSize.height = -imageSize.height;
-        }
-
-        // Set image flipping to match view. Don't know if this is really the best way
-        // to deal with flipped views and images.
-        if ([image isFlipped] != flipped)
-            [image setFlipped: flipped];
-
-        // draw!
-        [image drawInRect: NSMakeRect(position.x, position.y, imageSize.width, imageSize.height)
-            fromRect: NSMakeRect(0, 0, srcImageSize.width,
-            srcImageSize.height)
-            operation: NSCompositeSourceOver
-            fraction: 1.0];
-
-    }
-
-    [super drawWithFrame:cellFrame inView:controlView];
-#endif
-}
-
-- (NSSize)cellSize
-{
-    NSSize cellSize = [super cellSize];
-    cellSize.width += (image ? [image size].width + (imageSpacing.width * 2) : 0);
-    return cellSize;
-}
-
-@end
-
index 73a09d8a7d984796c9c77a40c51c01117b83e536..99dcc10c8fcfc6d2d5fcfaf08ff602be0d83a307 100644 (file)
@@ -12,7 +12,8 @@
 @property (nonatomic, readonly) BOOL mp4OptionsEnabled;
 @property (nonatomic, readonly) BOOL mp4iPodCompatibleEnabled;
 
-@property (nonatomic, readonly) NSArray *angles;
+@property (nonatomic, readonly) NSArray<NSString *> *angles;
+@property (nonatomic, readonly) NSArray<NSString *> *containers;
 
 @property (nonatomic, readonly) NSAttributedString *attributedTitleDescription;
 @property (nonatomic, readonly) NSAttributedString *attributedDescription;
index 56c721271da718d46c93ba6fb0fcda2a1542f9ea..095cc8697a4b317eb5b3bfa5f288491f720137c8 100644 (file)
@@ -51,9 +51,9 @@ static NSDictionary            *shortHeightAttr;
     return [NSSet setWithObjects:@"container", @"video.encoder", nil];
 }
 
-- (NSArray *)angles
+- (NSArray<NSString *> *)angles
 {
-    NSMutableArray *angles = [NSMutableArray array];
+    NSMutableArray<NSString *> *angles = [NSMutableArray array];
     for (int i = 1; i <= self.title.angles; i++)
     {
         [angles addObject:[NSString stringWithFormat: @"%d", i]];
@@ -61,9 +61,9 @@ static NSDictionary            *shortHeightAttr;
     return angles;
 }
 
-- (NSArray *)containers
+- (NSArray<NSString *> *)containers
 {
-    NSMutableArray *containers = [NSMutableArray array];
+    NSMutableArray<NSString *> *containers = [NSMutableArray array];
 
     for (const hb_container_t *container = hb_container_get_next(NULL);
          container != NULL;
index d62eee5fa81f8435e779b0735cd8f22445c2f721..28bb4af291ab023676bd463b83a171416cb363bd 100644 (file)
@@ -1,9 +1,8 @@
-//
-//  HBQueueItem.h
-//  HandBrake
-//
-//  Created by Damiano Galassi on 07/02/2019.
-//
+/*  HBQueueItem.m $
+
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr/>.
+ It may be used under the terms of the GNU General Public License. */
 
 #import <Foundation/Foundation.h>
 #import "HBDistributedArray.h"
index 9a24385a25b5fe32bba379a682ec1bd35aa0a932..bdcbc70026b3386240765ecd20ed1dfbd361a672 100644 (file)
@@ -1,9 +1,8 @@
-//
-//  HBQueueItem.m
-//  HandBrake
-//
-//  Created by Damiano Galassi on 07/02/2019.
-//
+/*  HBQueueItem.m $
+
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr/>.
+ It may be used under the terms of the GNU General Public License. */
 
 #import "HBQueueItem.h"
 
@@ -90,7 +89,7 @@ static NSString *versionKey = @"HBQueueItemVersion";
     if (version == 1 && (self = [super init]))
     {
         decodeInt(_state);
-        if (_state > HBQueueItemStateFailed)
+        if (_state < HBQueueItemStateReady || _state > HBQueueItemStateFailed)
         {
             goto fail;
         }
diff --git a/macosx/HBTabView.h b/macosx/HBTabView.h
deleted file mode 100644 (file)
index 8efba02..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-/* HBTabView
-
- This file is part of the HandBrake source code.
- Homepage: <http://handbrake.fr/>.
- It may be used under the terms of the GNU General Public License.
- */
-
-#import <Cocoa/Cocoa.h>
-
-@interface HBTabView : NSTabView
-
-@property (nullable, assign) IBOutlet id<NSDraggingDestination> dropDelegate;
-
-@end
diff --git a/macosx/HBTabView.m b/macosx/HBTabView.m
deleted file mode 100644 (file)
index dc20f02..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-/* HBTabView
-
- This file is part of the HandBrake source code.
- Homepage: <http://handbrake.fr/>.
- It may be used under the terms of the GNU General Public License.
- */
-
-#import "HBTabView.h"
-
-@implementation HBTabView
-
-- (NSDragOperation)draggingEntered:(id<NSDraggingInfo>)sender
-{
-    return [self.dropDelegate draggingEntered:sender];
-}
-
-- (BOOL)prepareForDragOperation:(id<NSDraggingInfo>)sender
-{
-    return [self.dropDelegate prepareForDragOperation:sender];
-}
-
-- (BOOL)performDragOperation:(id <NSDraggingInfo>)sender
-{
-    return [self.dropDelegate performDragOperation:sender];
-}
-
-- (void)draggingExited:(nullable id <NSDraggingInfo>)sender
-{
-    [self.dropDelegate draggingExited:sender];
-}
-
-@end
index f19a4e4fc9025256b508aa82bfdd1852bcc1f446..40d39ac424b60ae1de3124862b24a212100ddccd 100644 (file)
@@ -47,7 +47,6 @@
                273F208B14ADBE3B0021BE6D /* test.c in Sources */ = {isa = PBXBuildFile; fileRef = 273F208814ADBE3B0021BE6D /* test.c */; };
                273F20AC14ADBE670021BE6D /* HBController.m in Sources */ = {isa = PBXBuildFile; fileRef = 273F208F14ADBE670021BE6D /* HBController.m */; };
                273F20AF14ADBE670021BE6D /* HBAudioController.m in Sources */ = {isa = PBXBuildFile; fileRef = 273F209414ADBE670021BE6D /* HBAudioController.m */; };
-               273F20B214ADBE670021BE6D /* HBImageAndTextCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 273F209A14ADBE670021BE6D /* HBImageAndTextCell.m */; };
                273F20B314ADBE670021BE6D /* HBOutputPanelController.m in Sources */ = {isa = PBXBuildFile; fileRef = 273F209C14ADBE670021BE6D /* HBOutputPanelController.m */; };
                273F20B414ADBE670021BE6D /* HBOutputRedirect.m in Sources */ = {isa = PBXBuildFile; fileRef = 273F209E14ADBE670021BE6D /* HBOutputRedirect.m */; };
                273F20B514ADBE670021BE6D /* HBPreferencesController.m in Sources */ = {isa = PBXBuildFile; fileRef = 273F20A014ADBE670021BE6D /* HBPreferencesController.m */; };
@@ -86,7 +85,7 @@
                A91485FE1F61296100374C12 /* HBFiltersViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = A91485FD1F61296100374C12 /* HBFiltersViewController.m */; };
                A914BCB31BC441C700157917 /* HBPreviewView.m in Sources */ = {isa = PBXBuildFile; fileRef = A914BCB21BC441C700157917 /* HBPreviewView.m */; };
                A916180E1C845161000556C6 /* NSDictionary+HBAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = A93B0DF71C804CF50051A3FA /* NSDictionary+HBAdditions.m */; };
-               A916C9921C84498F00C7B560 /* DockTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 46AB433415F98A2B009C0961 /* DockTextField.m */; };
+               A916C9921C84498F00C7B560 /* HBDockTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 46AB433415F98A2B009C0961 /* HBDockTextField.m */; };
                A916C9931C8449A100C7B560 /* HBAddPresetController.m in Sources */ = {isa = PBXBuildFile; fileRef = A9E2FD251A21BC4A000E8D3F /* HBAddPresetController.m */; };
                A916C9951C8449B000C7B560 /* HBChapterTitlesController.m in Sources */ = {isa = PBXBuildFile; fileRef = A91726E6197291BC00D1AFEF /* HBChapterTitlesController.m */; };
                A916C9961C8449BE00C7B560 /* HBJobOutputFileWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = A91AFD0E1A949472009BECED /* HBJobOutputFileWriter.m */; };
                A9CE0A921F57EC3400724577 /* HBImageUtilities.m in Sources */ = {isa = PBXBuildFile; fileRef = A9CE0A911F57EC3400724577 /* HBImageUtilities.m */; };
                A9CF25F71990D6820023F727 /* HBPresetsViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = A9CF25F61990D6820023F727 /* HBPresetsViewController.m */; };
                A9D0FA771C1C284D0003F2A9 /* HBFocusRingView.m in Sources */ = {isa = PBXBuildFile; fileRef = A9D0FA761C1C284D0003F2A9 /* HBFocusRingView.m */; };
-               A9D0FA7A1C1C36820003F2A9 /* HBTabView.m in Sources */ = {isa = PBXBuildFile; fileRef = A9D0FA791C1C36820003F2A9 /* HBTabView.m */; };
                A9D1E41718262364002F6424 /* HBPreviewGenerator.m in Sources */ = {isa = PBXBuildFile; fileRef = A9D1E41618262364002F6424 /* HBPreviewGenerator.m */; };
                A9D363512209C08600D8EFEA /* HBQueueItemView.m in Sources */ = {isa = PBXBuildFile; fileRef = A9D363502209C08500D8EFEA /* HBQueueItemView.m */; };
                A9DC6C52196F04F6002AE6B4 /* HBSubtitlesController.m in Sources */ = {isa = PBXBuildFile; fileRef = A9DC6C50196F04F6002AE6B4 /* HBSubtitlesController.m */; };
                273F209414ADBE670021BE6D /* HBAudioController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBAudioController.m; sourceTree = "<group>"; };
                273F209714ADBE670021BE6D /* HBDVDDetector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HBDVDDetector.h; sourceTree = "<group>"; };
                273F209814ADBE670021BE6D /* HBDVDDetector.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBDVDDetector.m; sourceTree = "<group>"; };
-               273F209914ADBE670021BE6D /* HBImageAndTextCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HBImageAndTextCell.h; sourceTree = "<group>"; };
-               273F209A14ADBE670021BE6D /* HBImageAndTextCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBImageAndTextCell.m; sourceTree = "<group>"; };
                273F209B14ADBE670021BE6D /* HBOutputPanelController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HBOutputPanelController.h; sourceTree = "<group>"; };
                273F209C14ADBE670021BE6D /* HBOutputPanelController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBOutputPanelController.m; sourceTree = "<group>"; };
                273F209D14ADBE670021BE6D /* HBOutputRedirect.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HBOutputRedirect.h; sourceTree = "<group>"; };
                27D6C73F14B102DA00B785E4 /* libx264.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libx264.a; path = external/contrib/lib/libx264.a; sourceTree = BUILT_PRODUCTS_DIR; };
                27D6C74014B102DA00B785E4 /* libxml2.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libxml2.a; path = external/contrib/lib/libxml2.a; sourceTree = BUILT_PRODUCTS_DIR; };
                3490BCB31614CF8D002A5AD7 /* HandBrake.icns */ = {isa = PBXFileReference; lastKnownFileType = image.icns; path = HandBrake.icns; sourceTree = "<group>"; };
-               46AB433315F98A2B009C0961 /* DockTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DockTextField.h; sourceTree = "<group>"; };
-               46AB433415F98A2B009C0961 /* DockTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DockTextField.m; sourceTree = "<group>"; };
+               46AB433315F98A2B009C0961 /* HBDockTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HBDockTextField.h; sourceTree = "<group>"; };
+               46AB433415F98A2B009C0961 /* HBDockTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBDockTextField.m; sourceTree = "<group>"; };
                A900E6BC1D7B1B4800CB6C0A /* libopus.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libopus.a; path = external/contrib/lib/libopus.a; sourceTree = BUILT_PRODUCTS_DIR; };
                A903C55E1CCE78060026B0ED /* NSWindow+HBAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSWindow+HBAdditions.h"; sourceTree = "<group>"; };
                A903C55F1CCE78060026B0ED /* NSWindow+HBAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSWindow+HBAdditions.m"; sourceTree = "<group>"; };
                A9CF25F61990D6820023F727 /* HBPresetsViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBPresetsViewController.m; sourceTree = "<group>"; };
                A9D0FA751C1C284D0003F2A9 /* HBFocusRingView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HBFocusRingView.h; sourceTree = "<group>"; };
                A9D0FA761C1C284D0003F2A9 /* HBFocusRingView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBFocusRingView.m; sourceTree = "<group>"; };
-               A9D0FA781C1C36820003F2A9 /* HBTabView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HBTabView.h; sourceTree = "<group>"; };
-               A9D0FA791C1C36820003F2A9 /* HBTabView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBTabView.m; sourceTree = "<group>"; };
                A9D1E41618262364002F6424 /* HBPreviewGenerator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBPreviewGenerator.m; sourceTree = "<group>"; };
                A9D3634F2209C08500D8EFEA /* HBQueueItemView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = HBQueueItemView.h; sourceTree = "<group>"; };
                A9D363502209C08500D8EFEA /* HBQueueItemView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = HBQueueItemView.m; sourceTree = "<group>"; };
                                A95BA15C220C968500A2F9F9 /* HBQueueItem.m */,
                                A9D3634F2209C08500D8EFEA /* HBQueueItemView.h */,
                                A9D363502209C08500D8EFEA /* HBQueueItemView.m */,
-                               A9EA43661A2210C400785E95 /* HBTableView.h */,
-                               A9EA43671A2210C400785E95 /* HBTableView.m */,
                                A9AA447C1970726500D7DEFC /* HBQueueController.h */,
                                A9906B2B1A710920001D82D5 /* HBQueueController.m */,
                                A9A96BD220CAD63000A39AFB /* Queue.xib */,
                        children = (
                                A9BC24C71A69293E007DC41A /* HBAttributedStringAdditions.h */,
                                A9BC24C81A69293E007DC41A /* HBAttributedStringAdditions.m */,
-                               46AB433315F98A2B009C0961 /* DockTextField.h */,
-                               46AB433415F98A2B009C0961 /* DockTextField.m */,
+                               46AB433315F98A2B009C0961 /* HBDockTextField.h */,
+                               46AB433415F98A2B009C0961 /* HBDockTextField.m */,
                                A9F7102419A475EC00F61301 /* HBDockTile.h */,
                                A9F7102519A475EC00F61301 /* HBDockTile.m */,
-                               273F209914ADBE670021BE6D /* HBImageAndTextCell.h */,
-                               273F209A14ADBE670021BE6D /* HBImageAndTextCell.m */,
+                               A9EA43661A2210C400785E95 /* HBTableView.h */,
+                               A9EA43671A2210C400785E95 /* HBTableView.m */,
                                A9D0FA751C1C284D0003F2A9 /* HBFocusRingView.h */,
                                A9D0FA761C1C284D0003F2A9 /* HBFocusRingView.m */,
-                               A9D0FA781C1C36820003F2A9 /* HBTabView.h */,
-                               A9D0FA791C1C36820003F2A9 /* HBTabView.m */,
                                A93B49201DA3AA6900DD70A3 /* HBToolbarBadgedItem.h */,
                                A93B49211DA3AA6900DD70A3 /* HBToolbarBadgedItem.m */,
                        );
                                A916C9961C8449BE00C7B560 /* HBJobOutputFileWriter.m in Sources */,
                                A916C9951C8449B000C7B560 /* HBChapterTitlesController.m in Sources */,
                                A916C9931C8449A100C7B560 /* HBAddPresetController.m in Sources */,
-                               A916C9921C84498F00C7B560 /* DockTextField.m in Sources */,
+                               A916C9921C84498F00C7B560 /* HBDockTextField.m in Sources */,
                                A9706CB41AC1436F00BAEAA8 /* HBApplication.m in Sources */,
                                273F20B514ADBE670021BE6D /* HBPreferencesController.m in Sources */,
                                273F20AC14ADBE670021BE6D /* HBController.m in Sources */,
                                A92268781A6E555500A8D5C5 /* HBAppDelegate.m in Sources */,
                                A98036CD1CCA91DD007661AA /* HBAVPlayer.m in Sources */,
                                A9BC24C91A69293E007DC41A /* HBAttributedStringAdditions.m in Sources */,
-                               273F20B214ADBE670021BE6D /* HBImageAndTextCell.m in Sources */,
                                273F20B314ADBE670021BE6D /* HBOutputPanelController.m in Sources */,
                                273F20B414ADBE670021BE6D /* HBOutputRedirect.m in Sources */,
                                A95BA15D220C968500A2F9F9 /* HBQueueItem.m in Sources */,
                                A9D0FA771C1C284D0003F2A9 /* HBFocusRingView.m in Sources */,
-                               A9D0FA7A1C1C36820003F2A9 /* HBTabView.m in Sources */,
                                A91AFD0C1A948827009BECED /* HBOutputFileWriter.m in Sources */,
                                A9D363512209C08600D8EFEA /* HBQueueItemView.m in Sources */,
                                A95121E61B5F7BE700FD773D /* NSArray+HBAdditions.m in Sources */,