Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
497db07a
Commit
497db07a
authored
Jun 29, 2013
by
David Fuhrmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
macosx: CAS: eye candy and {en,dis}abling logic for customize panel
parent
64daf779
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
1979 additions
and
1676 deletions
+1979
-1676
extras/package/macosx/Resources/English.lproj/ConvertAndSave.xib
...package/macosx/Resources/English.lproj/ConvertAndSave.xib
+1912
-1676
modules/gui/macosx/ConvertAndSave.h
modules/gui/macosx/ConvertAndSave.h
+9
-0
modules/gui/macosx/ConvertAndSave.m
modules/gui/macosx/ConvertAndSave.m
+25
-0
modules/gui/macosx/misc.h
modules/gui/macosx/misc.h
+8
-0
modules/gui/macosx/misc.m
modules/gui/macosx/misc.m
+25
-0
No files found.
extras/package/macosx/Resources/English.lproj/ConvertAndSave.xib
View file @
497db07a
This source diff could not be displayed because it is too large. You can
view the blob
instead.
modules/gui/macosx/ConvertAndSave.h
View file @
497db07a
...
...
@@ -62,6 +62,8 @@
IBOutlet
id
_customize_newProfile_btn
;
IBOutlet
id
_customize_tabview
;
IBOutlet
id
_customize_encap_matrix
;
IBOutlet
id
_customize_vid_settings_box
;
IBOutlet
id
_customize_vid_ckb
;
IBOutlet
id
_customize_vid_keep_ckb
;
IBOutlet
id
_customize_vid_codec_lbl
;
...
...
@@ -78,6 +80,8 @@
IBOutlet
id
_customize_vid_height_fld
;
IBOutlet
id
_customize_vid_scale_lbl
;
IBOutlet
id
_customize_vid_scale_pop
;
IBOutlet
id
_customize_aud_settings_box
;
IBOutlet
id
_customize_aud_ckb
;
IBOutlet
id
_customize_aud_keep_ckb
;
IBOutlet
id
_customize_aud_codec_lbl
;
...
...
@@ -88,6 +92,7 @@
IBOutlet
id
_customize_aud_channels_fld
;
IBOutlet
id
_customize_aud_samplerate_lbl
;
IBOutlet
id
_customize_aud_samplerate_pop
;
IBOutlet
id
_customize_subs_ckb
;
IBOutlet
id
_customize_subs_pop
;
IBOutlet
id
_customize_subs_overlay_ckb
;
...
...
@@ -158,6 +163,10 @@
-
(
void
)
panel
:(
VLCEnterTextPanel
*
)
panel
returnValue
:(
NSUInteger
)
value
text
:(
NSString
*
)
text
;
-
(
void
)
panel
:(
VLCSelectItemInPopupPanel
*
)
panel
returnValue
:(
NSUInteger
)
value
item
:(
NSUInteger
)
item
;
-
(
IBAction
)
videoSettingsChanged
:(
id
)
sender
;
-
(
IBAction
)
audioSettingsChanged
:(
id
)
sender
;
-
(
IBAction
)
subSettingsChanged
:(
id
)
sender
;
-
(
void
)
updateDropView
;
@end
...
...
modules/gui/macosx/ConvertAndSave.m
View file @
497db07a
...
...
@@ -641,6 +641,27 @@ static VLCConvertAndSave *_o_sharedInstance = nil;
}
}
-
(
IBAction
)
videoSettingsChanged
:(
id
)
sender
{
bool
enableSettings
=
[
_customize_vid_ckb
state
]
==
NSOnState
&&
[
_customize_vid_keep_ckb
state
]
==
NSOffState
;
[
_customize_vid_settings_box
enableSubviews
:
enableSettings
];
[
_customize_vid_keep_ckb
setEnabled
:[
_customize_vid_ckb
state
]
==
NSOnState
];
}
-
(
IBAction
)
audioSettingsChanged
:(
id
)
sender
{
bool
enableSettings
=
[
_customize_aud_ckb
state
]
==
NSOnState
&&
[
_customize_aud_keep_ckb
state
]
==
NSOffState
;
[
_customize_aud_settings_box
enableSubviews
:
enableSettings
];
[
_customize_aud_keep_ckb
setEnabled
:[
_customize_aud_ckb
state
]
==
NSOnState
];
}
-
(
IBAction
)
subSettingsChanged
:(
id
)
sender
{
bool
enableSettings
=
[
_customize_subs_ckb
state
]
==
NSOnState
;
[
_customize_subs_overlay_ckb
setEnabled
:
enableSettings
];
[
_customize_subs_pop
setEnabled
:
enableSettings
];
}
# pragma mark -
# pragma mark Private Functionality
-
(
void
)
updateDropView
...
...
@@ -750,6 +771,10 @@ static VLCConvertAndSave *_o_sharedInstance = nil;
}
}
[
self
videoSettingsChanged
:
nil
];
[
self
audioSettingsChanged
:
nil
];
[
self
subSettingsChanged
:
nil
];
[
self
setCurrentProfile
:
[[[
NSMutableArray
alloc
]
initWithArray
:
[
profileString
componentsSeparatedByString
:
@";"
]]
autorelease
]];
}
...
...
modules/gui/macosx/misc.h
View file @
497db07a
...
...
@@ -211,3 +211,11 @@
-
(
bool
)
isPartialStringValid
:(
NSString
*
)
partialString
newEditingString
:(
NSString
**
)
newString
errorDescription
:(
NSString
**
)
error
;
@end
/*****************************************************************************
* NSView addition
*****************************************************************************/
@interface
NSView
(
EnableSubviews
)
-
(
void
)
enableSubviews
:(
BOOL
)
b_enable
;
@end
\ No newline at end of file
modules/gui/macosx/misc.m
View file @
497db07a
...
...
@@ -856,4 +856,29 @@ void _drawFrameInRect(NSRect frameRect)
}
@end
@implementation
NSView
(
EnableSubviews
)
-
(
void
)
enableSubviews
:(
BOOL
)
b_enable
{
for
(
NSView
*
o_view
in
[
self
subviews
])
{
[
o_view
enableSubviews
:
b_enable
];
// enable NSControl
if
([
o_view
respondsToSelector
:
@selector
(
setEnabled
:)])
{
[(
NSControl
*
)
o_view
setEnabled
:
b_enable
];
}
// also "enable / disable" text views
if
([
o_view
respondsToSelector
:
@selector
(
setTextColor
:)])
{
if
(
b_enable
==
NO
)
{
[(
NSTextField
*
)
o_view
setTextColor
:[
NSColor
disabledControlTextColor
]];
}
else
{
[(
NSTextField
*
)
o_view
setTextColor
:[
NSColor
controlTextColor
]];
}
}
}
}
@end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment