Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
8fecaa83
Commit
8fecaa83
authored
Jul 13, 2008
by
Pierre d'Herbemont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
macosx: Make sure there is a title or a name for the input item.
parent
35ce0c33
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
5 deletions
+11
-5
modules/gui/macosx/playlistinfo.m
modules/gui/macosx/playlistinfo.m
+11
-5
No files found.
modules/gui/macosx/playlistinfo.m
View file @
8fecaa83
...
@@ -218,6 +218,7 @@ static VLCInfo *_o_sharedInstance = nil;
...
@@ -218,6 +218,7 @@ static VLCInfo *_o_sharedInstance = nil;
if
(
_p_item
!=
p_item
)
if
(
_p_item
!=
p_item
)
{
{
if
(
p_item
)
vlc_gc_decref
(
p_item
);
if
(
p_item
)
vlc_gc_decref
(
p_item
);
[
o_saveMetaData_btn
setEnabled
:
NO
];
if
(
_p_item
)
vlc_gc_incref
(
_p_item
);
if
(
_p_item
)
vlc_gc_incref
(
_p_item
);
p_item
=
_p_item
;
p_item
=
_p_item
;
}
}
...
@@ -244,10 +245,6 @@ static VLCInfo *_o_sharedInstance = nil;
...
@@ -244,10 +245,6 @@ static VLCInfo *_o_sharedInstance = nil;
}
}
else
else
{
{
/* fill uri info */
char
*
psz_url
=
input_item_GetURI
(
p_item
);
[
o_uri_txt
setStringValue
:
[
NSString
stringWithUTF8String
:
psz_url
?
psz_url
:
""
]];
if
(
!
input_item_IsPreparsed
(
p_item
)
)
if
(
!
input_item_IsPreparsed
(
p_item
)
)
{
{
playlist_t
*
p_playlist
=
pl_Yield
(
VLCIntf
);
playlist_t
*
p_playlist
=
pl_Yield
(
VLCIntf
);
...
@@ -255,15 +252,24 @@ static VLCInfo *_o_sharedInstance = nil;
...
@@ -255,15 +252,24 @@ static VLCInfo *_o_sharedInstance = nil;
pl_Release
(
VLCIntf
);
pl_Release
(
VLCIntf
);
}
}
/* fill uri info */
char
*
psz_url
=
input_item_GetURI
(
p_item
);
[
o_uri_txt
setStringValue
:
[
NSString
stringWithUTF8String
:
psz_url
?
psz_url
:
""
]];
free
(
psz_url
);
free
(
psz_url
);
/* fill title info */
char
*
psz_title
=
input_item_GetTitle
(
p_item
);
if
(
!
psz_title
)
psz_title
=
input_item_GetName
(
p_item
);
[
o_title_txt
setStringValue
:
[
NSString
stringWithUTF8String
:
psz_title
?
:
""
]];
free
(
psz_title
);
#define SET( foo, bar ) \
#define SET( foo, bar ) \
char *psz_##foo = input_item_Get##bar ( p_item ); \
char *psz_##foo = input_item_Get##bar ( p_item ); \
[self setMeta: psz_##foo forLabel: o_##foo##_txt]; \
[self setMeta: psz_##foo forLabel: o_##foo##_txt]; \
FREENULL( psz_##foo );
FREENULL( psz_##foo );
/* fill the other fields */
/* fill the other fields */
SET
(
title
,
Title
);
SET
(
author
,
Artist
);
SET
(
author
,
Artist
);
SET
(
collection
,
Album
);
SET
(
collection
,
Album
);
SET
(
seqNum
,
TrackNum
);
SET
(
seqNum
,
TrackNum
);
...
...
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