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
5f92719d
Commit
5f92719d
authored
Feb 03, 2010
by
Toralf Niebuhr
Committed by
Pierre d'Herbemont
Feb 04, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
macosx/framework: Remove libvlc_exception_t where needed.
Signed-off-by:
Pierre d'Herbemont
<
pdherbemont@free.fr
>
parent
2cb15bea
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
27 deletions
+7
-27
projects/macosx/framework/Sources/VLCMedia.m
projects/macosx/framework/Sources/VLCMedia.m
+3
-13
projects/macosx/framework/Sources/VLCMediaDiscoverer.m
projects/macosx/framework/Sources/VLCMediaDiscoverer.m
+1
-5
projects/macosx/framework/Sources/VLCMediaList.m
projects/macosx/framework/Sources/VLCMediaList.m
+3
-9
No files found.
projects/macosx/framework/Sources/VLCMedia.m
View file @
5f92719d
...
...
@@ -177,13 +177,8 @@ static void HandleMediaSubItemAdded(const libvlc_event_t * event, void * self)
{
if
(
self
=
[
super
init
])
{
libvlc_exception_t
ex
;
libvlc_exception_init
(
&
ex
);
p_md
=
libvlc_media_new
([
VLCLibrary
sharedInstance
],
[[
anURL
absoluteString
]
UTF8String
],
&
ex
);
catch_exception
(
&
ex
);
[[
anURL
absoluteString
]
UTF8String
]);
delegate
=
nil
;
metaDictionary
=
[[
NSMutableDictionary
alloc
]
initWithCapacity
:
3
];
...
...
@@ -201,13 +196,8 @@ static void HandleMediaSubItemAdded(const libvlc_event_t * event, void * self)
{
if
(
self
=
[
super
init
])
{
libvlc_exception_t
ex
;
libvlc_exception_init
(
&
ex
);
p_md
=
libvlc_media_new_as_node
([
VLCLibrary
sharedInstance
],
[
aName
UTF8String
],
&
ex
);
catch_exception
(
&
ex
);
[
aName
UTF8String
]);
delegate
=
nil
;
metaDictionary
=
[[
NSMutableDictionary
alloc
]
initWithCapacity
:
3
];
...
...
@@ -277,7 +267,7 @@ static void HandleMediaSubItemAdded(const libvlc_event_t * event, void * self)
if
(
!
length
)
{
// Try figuring out what the length is
long
long
duration
=
libvlc_media_get_duration
(
p_md
,
NULL
);
long
long
duration
=
libvlc_media_get_duration
(
p_md
);
if
(
duration
>
-
1
)
{
length
=
[[
VLCTime
timeWithNumber
:[
NSNumber
numberWithLongLong
:
duration
]]
retain
];
...
...
projects/macosx/framework/Sources/VLCMediaDiscoverer.m
View file @
5f92719d
...
...
@@ -89,14 +89,10 @@ static void HandleMediaDiscovererEnded( const libvlc_event_t * event, void * use
{
if
(
self
=
[
super
init
])
{
libvlc_exception_t
ex
;
libvlc_exception_init
(
&
ex
);
localizedName
=
nil
;
discoveredMedia
=
nil
;
mdis
=
libvlc_media_discoverer_new_from_name
([
VLCLibrary
sharedInstance
],
[
aServiceName
UTF8String
],
&
ex
);
catch_exception
(
&
ex
);
[
aServiceName
UTF8String
]);
libvlc_event_manager_t
*
p_em
=
libvlc_media_discoverer_event_manager
(
mdis
);
libvlc_event_attach
(
p_em
,
libvlc_MediaDiscovererStarted
,
HandleMediaDiscovererStarted
,
self
);
...
...
projects/macosx/framework/Sources/VLCMediaList.m
View file @
5f92719d
...
...
@@ -146,10 +146,7 @@ static void HandleMediaListItemDeleted( const libvlc_event_t * event, void * use
[
media
retain
];
// Add it to the libvlc's medialist
libvlc_exception_t
p_e
;
libvlc_exception_init
(
&
p_e
);
libvlc_media_list_insert_media
(
p_mlist
,
[
media
libVLCMediaDescriptor
],
index
,
&
p_e
);
catch_exception
(
&
p_e
);
libvlc_media_list_insert_media
(
p_mlist
,
[
media
libVLCMediaDescriptor
],
index
);
}
-
(
void
)
removeMediaAtIndex
:(
NSInteger
)
index
...
...
@@ -157,10 +154,7 @@ static void HandleMediaListItemDeleted( const libvlc_event_t * event, void * use
[[
self
mediaAtIndex
:
index
]
release
];
// Remove it from the libvlc's medialist
libvlc_exception_t
p_e
;
libvlc_exception_init
(
&
p_e
);
libvlc_media_list_remove_index
(
p_mlist
,
index
,
&
p_e
);
catch_exception
(
&
p_e
);
libvlc_media_list_remove_index
(
p_mlist
,
index
);
}
-
(
VLCMedia
*
)
mediaAtIndex
:(
NSInteger
)
index
...
...
@@ -227,7 +221,7 @@ static void HandleMediaListItemDeleted( const libvlc_event_t * event, void * use
NSUInteger
i
,
count
=
libvlc_media_list_count
(
p_mlist
);
for
(
i
=
0
;
i
<
count
;
i
++
)
{
libvlc_media_t
*
p_md
=
libvlc_media_list_item_at_index
(
p_mlist
,
i
,
NULL
);
libvlc_media_t
*
p_md
=
libvlc_media_list_item_at_index
(
p_mlist
,
i
);
[
cachedMedia
addObject
:[
VLCMedia
mediaWithLibVLCMediaDescriptor
:
p_md
]];
libvlc_media_release
(
p_md
);
}
...
...
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