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
53aab251
Commit
53aab251
authored
May 04, 2007
by
Pierre d'Herbemont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Mac OS X gui: Quick Preferences fix.
parent
2cc6ce41
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
30 additions
and
42 deletions
+30
-42
modules/gui/macosx/prefs.m
modules/gui/macosx/prefs.m
+2
-2
modules/gui/macosx/prefs_widgets.m
modules/gui/macosx/prefs_widgets.m
+28
-40
No files found.
modules/gui/macosx/prefs.m
View file @
53aab251
...
...
@@ -566,7 +566,7 @@ static VLCTreeItem *o_root_item = nil;
msg_Err
(
p_intf
,
"invalid preference item found"
);
break
;
}
if
(
p_item
<
p_end
)
if
(
p_item
>
p_end
)
break
;
switch
(
p_item
->
i_type
)
{
...
...
@@ -636,7 +636,7 @@ static VLCTreeItem *o_root_item = nil;
msg_Err
(
p_intf
,
"invalid preference item found"
);
break
;
}
if
(
p_item
<
p_end
)
if
(
p_item
>
p_end
)
break
;
switch
(
p_item
->
i_type
)
{
...
...
modules/gui/macosx/prefs_widgets.m
View file @
53aab251
...
...
@@ -1186,8 +1186,7 @@
[[
VLCMain
sharedInstance
]
localizedString:
(
char
*
)
p_item
->
psz_longtext
]
toWidth
:
PREFS_WRAP
];
if
(
p_item
->
value
.
psz
)
o_textfieldString
=
[[
VLCMain
sharedInstance
]
localizedString:
(
char
*
)
p_item
->
value
.
psz
];
o_textfieldString
=
[
NSString
stringWithFormat
:
@"%s"
,
(
char
*
)
p_item
->
value
.
psz
];
else
o_textfieldString
=
[
NSString
stringWithString
:
@""
];
ADD_TEXTFIELD
(
o_textfield
,
mainFrame
,
12
,
2
,
mainFrame
.
size
.
width
-
...
...
@@ -1267,7 +1266,6 @@
int
i_index
;
vlc_list_t
*
p_list
;
module_t
*
p_parser
;
module_config_t
*
p_end
;
i_view_type
=
CONFIG_ITEM_MODULE
;
/* add the label */
...
...
@@ -1296,7 +1294,7 @@
for
(
i_index
=
0
;
i_index
<
p_list
->
i_count
;
i_index
++
)
{
p_parser
=
(
module_t
*
)
p_list
->
p_values
[
i_index
].
p_object
;
p_end
=
p_item
+
p_parser
->
confsize
;
if
(
p_item
->
i_type
==
CONFIG_ITEM_MODULE
)
{
if
(
!
strcmp
(
p_parser
->
psz_capability
,
...
...
@@ -1313,13 +1311,14 @@
}
else
{
module_config_t
*
p_config
;
int
i
;
if
(
!
strcmp
(
p_parser
->
psz_object_name
,
"main"
)
)
continue
;
continue
;
p_config
=
p_parser
->
p_config
;
if
(
p_config
)
do
for
(
i
=
0
;
i
<
p_parser
->
confsize
;
i
++
)
{
module_config_t
*
p_config
=
p_parser
->
p_config
+
i
;
/* Hack: required subcategory is stored in i_min */
if
(
p_config
->
i_type
==
CONFIG_SUBCATEGORY
&&
p_config
->
value
.
i
==
p_item
->
min
.
i
)
...
...
@@ -1332,7 +1331,7 @@
p_parser
->
psz_object_name
)
)
[
o_popup
selectItem
:[
o_popup
lastItem
]];
}
}
while
(
p_item
<
p_end
&&
p_config
++
);
}
}
}
vlc_list_release
(
p_list
);
...
...
@@ -1365,16 +1364,15 @@
{
NSString
*
newval
=
[
o_popup
titleOfSelectedItem
];
char
*
returnval
=
NULL
;
int
i_index
;
int
i_
module_
index
;
vlc_list_t
*
p_list
;
module_t
*
p_parser
;
module_config_t
*
p_end
;
p_list
=
vlc_list_find
(
VLCIntf
,
VLC_OBJECT_MODULE
,
FIND_ANYWHERE
);
for
(
i_
index
=
0
;
i_index
<
p_list
->
i_count
;
i
_index
++
)
for
(
i_
module_index
=
0
;
i_module_index
<
p_list
->
i_count
;
i_module
_index
++
)
{
p_parser
=
(
module_t
*
)
p_list
->
p_values
[
i_index
].
p_object
;
p_end
=
p_item
+
p_parser
->
confsize
;
p_parser
=
(
module_t
*
)
p_list
->
p_values
[
i_
module_
index
].
p_object
;
if
(
p_item
->
i_type
==
CONFIG_ITEM_MODULE
)
{
if
(
!
strcmp
(
p_parser
->
psz_capability
,
...
...
@@ -1391,13 +1389,14 @@
}
else
{
module_config_t
*
p_config
;
int
i
;
if
(
!
strcmp
(
p_parser
->
psz_object_name
,
"main"
)
)
continue
;
continue
;
p_config
=
p_parser
->
p_config
;
if
(
p_config
)
do
for
(
i
=
0
;
i
<
p_parser
->
confsize
;
i
++
)
{
module_config_t
*
p_config
=
p_parser
->
p_config
+
i
;
/* Hack: required subcategory is stored in i_min */
if
(
p_config
->
i_type
==
CONFIG_SUBCATEGORY
&&
p_config
->
value
.
i
==
p_item
->
min
.
i
)
...
...
@@ -1410,7 +1409,7 @@
break
;
}
}
}
while
(
p_item
<
p_end
&&
p_config
++
);
}
}
}
vlc_list_release
(
p_list
);
...
...
@@ -1423,7 +1422,7 @@
withView
:
(
NSView
*
)
o_parent_view
{
NSRect
mainFrame
=
[
o_parent_view
frame
];
NSString
*
o_labelString
,
*
o_tooltip
,
*
o_textfieldString
;
NSString
*
o_labelString
,
*
o_tooltip
;
mainFrame
.
size
.
height
=
23
;
mainFrame
.
size
.
width
=
mainFrame
.
size
.
width
-
LEFTMARGIN
-
RIGHTMARGIN
+
1
;
mainFrame
.
origin
.
x
=
LEFTMARGIN
;
...
...
@@ -1454,12 +1453,6 @@
[
o_stepper
setAutoresizingMask
:
NSViewMaxXMargin
];
[
self
addSubview
:
o_stepper
];
/* build the textfield */
if
(
p_item
->
value
.
psz
)
o_textfieldString
=
[[
VLCMain
sharedInstance
]
localizedString:
(
char
*
)
p_item
->
value
.
psz
];
else
o_textfieldString
=
[
NSString
stringWithString
:
@""
];
ADD_TEXTFIELD
(
o_textfield
,
mainFrame
,
mainFrame
.
size
.
width
-
19
-
52
,
1
,
49
,
o_tooltip
,
@""
)
[
o_textfield
setIntValue
:
p_item
->
value
.
i
];
...
...
@@ -1720,7 +1713,7 @@
withView
:
(
NSView
*
)
o_parent_view
{
NSRect
mainFrame
=
[
o_parent_view
frame
];
NSString
*
o_labelString
,
*
o_tooltip
,
*
o_textfieldString
;
NSString
*
o_labelString
,
*
o_tooltip
;
mainFrame
.
size
.
height
=
23
;
mainFrame
.
size
.
width
=
mainFrame
.
size
.
width
-
LEFTMARGIN
-
RIGHTMARGIN
+
1
;
mainFrame
.
origin
.
x
=
LEFTMARGIN
;
...
...
@@ -1752,11 +1745,6 @@
[
self
addSubview
:
o_stepper
];
/* build the textfield */
if
(
p_item
->
value
.
psz
)
o_textfieldString
=
[[
VLCMain
sharedInstance
]
localizedString:
(
char
*
)
p_item
->
value
.
psz
];
else
o_textfieldString
=
[
NSString
stringWithString
:
@""
];
ADD_TEXTFIELD
(
o_textfield
,
mainFrame
,
mainFrame
.
size
.
width
-
19
-
52
,
1
,
49
,
o_tooltip
,
@""
)
[
o_textfield
setFloatValue
:
p_item
->
value
.
f
];
...
...
@@ -2060,27 +2048,27 @@ if( _p_item->i_type == CONFIG_ITEM_MODULE_LIST )
//Fill our array to know how may items we have...
vlc_list_t
*
p_list
;
module_t
*
p_parser
;
module_config_t
*
p_end
;
int
i_index
;
int
i_module_index
;
NSRect
mainFrame
=
[
o_parent_view
frame
];
NSString
*
o_labelString
,
*
o_textfieldString
,
*
o_tooltip
;
o_modulearray
=
[[
NSMutableArray
alloc
]
initWithCapacity
:
10
];
/* build a list of available modules */
p_list
=
vlc_list_find
(
VLCIntf
,
VLC_OBJECT_MODULE
,
FIND_ANYWHERE
);
for
(
i_
index
=
0
;
i_index
<
p_list
->
i_count
;
i
_index
++
)
for
(
i_
module_index
=
0
;
i_module_index
<
p_list
->
i_count
;
i_module
_index
++
)
{
p_parser
=
(
module_t
*
)
p_list
->
p_values
[
i_index
].
p_object
;
p_
end
=
p_item
+
p_parser
->
confsize
;
int
i
;
p_
parser
=
(
module_t
*
)
p_list
->
p_values
[
i_module_index
].
p_object
;
if
(
!
strcmp
(
p_parser
->
psz_object_name
,
"main"
)
)
continue
;
module_config_t
*
p_config
=
p_parser
->
p_config
;
if
(
p_config
)
do
for
(
i
=
0
;
i
<
p_parser
->
confsize
;
i
++
)
{
module_config_t
*
p_config
=
p_parser
->
p_config
+
i
;
NSString
*
o_modulelongname
,
*
o_modulename
;
NSNumber
*
o_moduleenabled
=
nil
;
/* Hack: required subcategory is stored in i_min */
if
(
p_config
->
i_type
==
CONFIG_SUBCATEGORY
&&
p_config
->
value
.
i
==
_p_item
->
min
.
i
)
...
...
@@ -2100,7 +2088,7 @@ if( _p_item->i_type == CONFIG_ITEM_MODULE_LIST )
arrayWithObjects:
o_modulename
,
o_modulelongname
,
o_moduleenabled
,
nil
]];
}
}
while
(
p_item
<
p_end
&&
p_config
++
);
}
}
vlc_list_release
(
p_list
);
...
...
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