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
2c83415d
Commit
2c83415d
authored
Jan 02, 2016
by
David Fuhrmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
macosx: Fix initialization of VLCPlaylist object
This is not loaded from a xib anymore, but rather manually.
parent
8eb81762
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
17 deletions
+19
-17
modules/gui/macosx/VLCPlaylist.m
modules/gui/macosx/VLCPlaylist.m
+19
-17
No files found.
modules/gui/macosx/VLCPlaylist.m
View file @
2c83415d
...
...
@@ -74,7 +74,6 @@
NSTableColumn
*
_sortTableColumn
;
BOOL
b_playlistmenu_nib_loaded
;
BOOL
b_view_setup
;
PLModel
*
_model
;
}
...
...
@@ -84,6 +83,22 @@
@implementation
VLCPlaylist
-
(
id
)
init
{
self
=
[
super
init
];
if
(
self
)
{
/* This uses a private API, but works fine on all current OSX releases.
* Radar ID 11739459 request a public API for this. However, it is probably
* easier and faster to recreate similar looking bitmaps ourselves. */
_ascendingSortingImage
=
[[
NSOutlineView
class
]
_defaultTableHeaderSortImage
];
_descendingSortingImage
=
[[
NSOutlineView
class
]
_defaultTableHeaderReverseSortImage
];
[[
NSNotificationCenter
defaultCenter
]
addObserver
:
self
selector
:
@selector
(
applicationWillTerminate
:
)
name
:
NSApplicationWillTerminateNotification
object
:
nil
];
}
return
self
;
}
+
(
void
)
initialize
{
NSUserDefaults
*
defaults
=
[
NSUserDefaults
standardUserDefaults
];
...
...
@@ -126,23 +141,8 @@
-
(
void
)
awakeFromNib
{
if
(
b_view_setup
)
return
;
[
self
reloadStyles
];
// This is only called for the playlist popup menu
[
self
initStrings
];
/* This uses a private API, but works fine on all current OSX releases.
* Radar ID 11739459 request a public API for this. However, it is probably
* easier and faster to recreate similar looking bitmaps ourselves. */
_ascendingSortingImage
=
[[
NSOutlineView
class
]
_defaultTableHeaderSortImage
];
_descendingSortingImage
=
[[
NSOutlineView
class
]
_defaultTableHeaderReverseSortImage
];
_sortTableColumn
=
nil
;
[[
NSNotificationCenter
defaultCenter
]
addObserver
:
self
selector
:
@selector
(
applicationWillTerminate
:
)
name
:
NSApplicationWillTerminateNotification
object
:
nil
];
b_view_setup
=
YES
;
}
-
(
void
)
setOutlineView
:(
VLCPlaylistView
*
__nullable
)
outlineView
...
...
@@ -162,6 +162,8 @@
[
_outlineView
setAllowsEmptySelection
:
NO
];
[
_outlineView
registerForDraggedTypes
:
[
NSArray
arrayWithObjects
:
NSFilenamesPboardType
,
@"VLCPlaylistItemPboardType"
,
nil
]];
[
_outlineView
setIntercellSpacing
:
NSMakeSize
(
0
.
0
,
1
.
0
)];
[
self
reloadStyles
];
}
-
(
void
)
setPlaylistHeaderView
:(
NSTableHeaderView
*
__nullable
)
playlistHeaderView
...
...
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