[vlc-commits] macosx: Listen for file tab changes

David Fuhrmann git at videolan.org
Fri Feb 3 10:52:23 CET 2017


vlc | branch: master | David Fuhrmann <dfuhrmann at videolan.org> | Thu Feb  2 17:20:46 2017 +0100| [f49deb8b13e9c8fa9a5f4e32fe2e85ab1c2bd593] | committer: David Fuhrmann

macosx: Listen for file tab changes

Added missing delegate for tab view.
Resets MRL in case device vanishes and list becomes empty.

refs #17715

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=f49deb8b13e9c8fa9a5f4e32fe2e85ab1c2bd593
---

 extras/package/macosx/Resources/English.lproj/Open.xib | 11 +++++++----
 modules/gui/macosx/VLCOpenWindowController.h           |  2 +-
 modules/gui/macosx/VLCOpenWindowController.m           |  1 +
 3 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/extras/package/macosx/Resources/English.lproj/Open.xib b/extras/package/macosx/Resources/English.lproj/Open.xib
index e1cd9b9..9c02473 100644
--- a/extras/package/macosx/Resources/English.lproj/Open.xib
+++ b/extras/package/macosx/Resources/English.lproj/Open.xib
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="11542" systemVersion="15G1108" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
+<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="11542" systemVersion="15G1217" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
     <dependencies>
         <deployment identifier="macosx"/>
         <development version="7000" identifier="xcode"/>
@@ -151,7 +151,7 @@
             <windowStyleMask key="styleMask" titled="YES"/>
             <windowPositionMask key="initialPositionMask" leftStrut="YES" rightStrut="YES" topStrut="YES" bottomStrut="YES"/>
             <rect key="contentRect" x="162" y="354" width="574" height="380"/>
-            <rect key="screenRect" x="0.0" y="0.0" width="1680" height="1027"/>
+            <rect key="screenRect" x="0.0" y="0.0" width="1280" height="777"/>
             <value key="minSize" type="size" width="213" height="107"/>
             <view key="contentView" id="637">
                 <rect key="frame" x="0.0" y="0.0" width="574" height="380"/>
@@ -551,6 +551,9 @@ Gw
                                 </view>
                             </tabViewItem>
                         </tabViewItems>
+                        <connections>
+                            <outlet property="delegate" destination="-2" id="xqg-Fo-ETa"/>
+                        </connections>
                     </tabView>
                     <button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="1256">
                         <rect key="frame" x="458" y="49" width="102" height="32"/>
@@ -607,7 +610,7 @@ Gw
             <windowStyleMask key="styleMask" titled="YES" closable="YES"/>
             <windowPositionMask key="initialPositionMask" leftStrut="YES" rightStrut="YES" topStrut="YES" bottomStrut="YES"/>
             <rect key="contentRect" x="37" y="107" width="531" height="324"/>
-            <rect key="screenRect" x="0.0" y="0.0" width="1680" height="1027"/>
+            <rect key="screenRect" x="0.0" y="0.0" width="1280" height="777"/>
             <value key="minSize" type="size" width="213" height="107"/>
             <view key="contentView" id="1264">
                 <rect key="frame" x="0.0" y="0.0" width="531" height="324"/>
@@ -1279,7 +1282,7 @@ Check the device's connection, make sure that the latest EyeTV software is insta
             <windowStyleMask key="styleMask" titled="YES" closable="YES"/>
             <windowPositionMask key="initialPositionMask" leftStrut="YES" rightStrut="YES" topStrut="YES" bottomStrut="YES"/>
             <rect key="contentRect" x="246" y="437" width="656" height="249"/>
-            <rect key="screenRect" x="0.0" y="0.0" width="1680" height="1027"/>
+            <rect key="screenRect" x="0.0" y="0.0" width="1280" height="777"/>
             <value key="minSize" type="size" width="213" height="107"/>
             <view key="contentView" id="2793">
                 <rect key="frame" x="0.0" y="0.0" width="656" height="249"/>
diff --git a/modules/gui/macosx/VLCOpenWindowController.h b/modules/gui/macosx/VLCOpenWindowController.h
index 918bfd4..8e3c866 100644
--- a/modules/gui/macosx/VLCOpenWindowController.h
+++ b/modules/gui/macosx/VLCOpenWindowController.h
@@ -26,7 +26,7 @@
 
 #import <Cocoa/Cocoa.h>
 
- at interface VLCOpenWindowController : NSWindowController
+ at interface VLCOpenWindowController : NSWindowController <NSTabViewDelegate>
 
 @property (readwrite, weak) IBOutlet NSTextField *mrlTextField;
 @property (readwrite, weak) IBOutlet NSTextField *mrlLabel;
diff --git a/modules/gui/macosx/VLCOpenWindowController.m b/modules/gui/macosx/VLCOpenWindowController.m
index 4b76d63..55177d6 100644
--- a/modules/gui/macosx/VLCOpenWindowController.m
+++ b/modules/gui/macosx/VLCOpenWindowController.m
@@ -906,6 +906,7 @@ struct display_info_t
     } else {
         msg_Dbg(getIntf(), "no optical media found");
         [_discSelectorPopup setHidden: YES];
+        [self setMRL:@""];
         [self showOpticalMediaView: _discNoDiscView withIcon: [NSImage imageNamed: @"NSApplicationIcon"]];
     }
 



More information about the vlc-commits mailing list