Commit Graph

1936 Commits

Author SHA1 Message Date
Steve Lhomme 72466c75ec vlc_input_item: rename INPUT_DURATION_UNKNOWN to INPUT_DURATION_INDEFINITE
For sources with no exact time limits, therefore it should not be used as such.
2018-07-30 07:15:30 +02:00
Filip Roséen 91450e0f82 control: oldrc: make it possible to adjust volume without playback
I don't know why 33464eacd6 introduced logic to prevent volume change
if the input is either paused, or not at all present, but from a
user's perspective this is not intuitive (as one of course can
adjust the volume even if nothing is playing).

fixes: #20897
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2018-07-25 11:15:57 +02:00
Hugo Beauzée-Luyssen d36e369e6a core: Remove old medialibrary 2018-07-17 23:53:01 +02:00
Pierre Lamot 09003c7627 ntservice: fix service command line truncated when using very long arguments
Close #20823

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2018-07-13 13:50:00 +02:00
Jean-Baptiste Kempf b007abf4c3 Remove RealRTSP plugin
Move to 21st century!
2018-07-11 18:50:49 +02:00
Steve Lhomme 51cb7df9ed modules: make use of the special duration value INPUT_DURATION_UNKNOWN
Instead of a hardcoded value (which is not VLC_TICK_INVALID)
2018-07-07 10:16:25 +02:00
Rémi Denis-Courmont 674aa28b6f hotkeys: fix format string
Regression from tick rework.
2018-07-06 19:44:32 +03:00
Steve Lhomme 18449933c8 modules: transform vlc_tick_t value to milliseconds with MS_FROM_VLC_TICK 2018-07-06 15:40:12 +02:00
Steve Lhomme 09d07968d6 hotkeys: replace hardcoded CLOCK_FREQ fractions by VLC_TICK_FROM_MS()
Easier to read and more explicit.
2018-07-05 16:41:41 +02:00
Steve Lhomme 641fb7d958 dbus_player: return the ticks in microseconds 2018-07-05 08:10:54 +02:00
Steve Lhomme 810840157d hotkeys: the audio/subtitle time are vlc_tick_t
They either get 0 or vlc_tick_now().
2018-07-03 16:13:30 +02:00
Steve Lhomme 026e60e342 core: the "spu-delay" is stored in vlc_tick_t
Convert the read/writes accordingly
2018-07-03 16:13:30 +02:00
Steve Lhomme 911569be2c modules: convert variables in seconds to ticks using vlc_tick_from_sec() 2018-07-03 15:28:24 +02:00
Steve Lhomme 1f17997348 rename VLC_TS_INVALID to VLC_TICK_INVALID 2018-07-03 07:10:07 +02:00
Steve Lhomme b4dfbc6283 rename mdate() to vlc_tick_now()
The lua "mdate" remains the same.
2018-06-22 13:32:10 +02:00
Steve Lhomme 8b0c6bb9fa rename msleep() to vlc_tick_sleep() 2018-06-22 13:29:09 +02:00
Steve Lhomme a6149e2c1e include: rename vlc_mtime.h to vlc_tick.h 2018-06-22 13:26:57 +02:00
Steve Lhomme ff56c92a5e rename mtime_t to vlc_tick_t
Keep a copy of vlc_tick_tfor backward compatibility.
2018-06-22 13:19:24 +02:00
Rémi Denis-Courmont d03f37b50d hotkeys: fix logic, copy-paste error
Regression from 73e4a2e888.
2018-06-17 11:25:36 +03:00
Steve Lhomme 5bb86a0cb4 oldrc: the value read from atoi is in seconds not mtime_t 2018-06-14 16:40:32 +02:00
Steve Lhomme 73e4a2e888 hotkeys: the delay up/down are processed in mtime_t
And with 50ms inc/decrements
2018-06-14 16:15:20 +02:00
Rémi Denis-Courmont 517a7e7b3f input item: use vlc_list for per-category infos 2018-06-13 19:30:19 +03:00
Erwan Tulou d1a4415266 hotkeys: fix crash when zooming 2018-06-11 23:08:48 +02:00
Rémi Denis-Courmont 0b3b1edf14 variables: use table of vlc_value_t for VLC_VAR_GETCHOICES
This simplifies the notation. No function differences.
2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 7a51579af2 hotkeys: separate immediate and string list handling 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont d5e48f174c hotkeys: remove tautology test 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 93b9545fe0 hotkeys: simplify 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 5882b2590f hotkeys: appropriate var_FreeList() 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 7048874668 variables: inline var_FreeList() in simple loops
This works like config choices.
2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 5d31da4eca variables: replace var_FreeList() with free()
...where applicable.
2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 5e50399a45 variables: add count parameter for VLC_VAR_GETCHOICES 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 34925c7cb5 variables: use char *** for VLC_VAR_GETCHOICES texts 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 1b380f31b1 variables: use char ** for VLC_VAR_GETTEXT 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 1fd0844ee7 oldrc: fix leak 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 2d605364a6 hotkeys: don't query unused texts 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont abfcbbbcee gestures: don't query unused texts 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont 63ce436225 variables: pass vlc_list_t directly with VLC_VAR_GETCHOICES 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont fe5fbf4349 variables: remove useless VLC_VAR_GETTEXT parameter 2018-06-10 13:08:44 +03:00
Rémi Denis-Courmont c95ca64e31 hotkeys: fix race on sys.vrnav.b_can_change 2018-06-06 19:58:34 +03:00
Rémi Denis-Courmont 027d4c43bd hotkeys: missing vout events (refs #20617) 2018-06-06 19:58:34 +03:00
Rémi Denis-Courmont 62fc1d1f86 hotkeys: take care of mouse wheel "key" events 2018-05-31 21:34:59 +03:00
Rémi Denis-Courmont bd00749be9 playlist: move pop-up menu variable 2018-05-31 21:07:31 +03:00
Rémi Denis-Courmont d0a4204fb2 hotkeys: handle pop-up menu setting 2018-05-31 21:04:34 +03:00
Rémi Denis-Courmont 4cedca0714 playlist: move FSC trigger and make it void 2018-05-31 21:00:14 +03:00
Rémi Denis-Courmont 0dbffe88b7 hotkeys: handle FSC toggling 2018-05-31 20:56:19 +03:00
Rémi Denis-Courmont 80acfd8982 hotkeys: use MOUSE_BUTTON_LEFT 2018-05-31 20:53:57 +03:00
Rémi Denis-Courmont 6f485a389b playlist: move intf-boss variable 2018-05-31 20:06:41 +03:00
Rémi Denis-Courmont 4c1816844e playlist: move intf-show and make it void 2018-05-31 20:06:41 +03:00
Romain Vimont bb21396e96 hotkeys: fix first subtitles toggle
A new hotkey to toggle subtitles visibility was introduced by commit
69d6f2ab18. The idea was to save the
current track id every time the subtitles track is switched via the
hotkey (v), and restore it on toggle (Shift+v).

However, the subtitle track is not necessarily changed via the hotkey:
it may be selected as a default subtitle, or switched from the menu for
example. As a consequence, the saved track id may be invalid.

To fix the issue, do not try to save the selected track id every time it
changes; instead, save it on toggle if subtitles are enabled, and
restore the track with the saved id if subtitles are disabled.

Fixes #16721

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2018-05-05 14:18:23 +02:00
Rémi Denis-Courmont d979cceee9 dbus: do not subtract VLC_TS_INVALID 2018-05-04 19:16:27 +03:00
Steve Lhomme 04db84cd9c modules: replace use of 1000000 on time values by CLOCK_FREQ
Modified-by: Thomas Guillem <thomas@gllm.fr>
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2018-05-04 11:29:09 +03:00
Rémi Denis-Courmont e3eddd4f7a mtime: remove LAST_MDATE
Almost every existing use cases uses INT64_MAX directly already. Also,
the signedness was wrong.
2018-05-02 18:57:00 +03:00
Romain Vimont 35a5a0ab24 hotkeys: fix SPU scaling limits
Otherwise it's impossible to reset the value to 100%
Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2018-04-19 13:07:06 +02:00
Rémi Denis-Courmont 3ddb87f88a oldrc: fix assertion failure (fixes #20123) 2018-03-23 06:43:58 +02:00
Hugo Beauzée-Luyssen dab13a3c28 intromsg: Ensure non-ascii characters are properly displayed on win32 2018-03-21 10:29:44 +01:00
Hugo Beauzée-Luyssen b349484398 dummy intf: Deprecate dummy-quiet option 2018-03-21 10:29:13 +01:00
Hugo Beauzée-Luyssen 2bc26eb597 dummy: Never show intromsg 2018-03-21 10:21:03 +01:00
Hugo Beauzée-Luyssen f729d67bfa oldrc: Handle non-ascii character
And revector a bit
refs #19874

(cherry picked from commit c1becb6c89f222f4d16b4ffd970ce5394d599938)
Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2018-03-14 09:54:38 +01:00
Rémi Denis-Courmont 52341c8b3d config: remove unused config_PutPsz() parameter 2018-02-28 20:07:26 +02:00
Hugo Beauzée-Luyssen 8c1c9a4322 oldrc: Accept backward compatible hosts
Fix #19871
2018-02-28 17:52:49 +01:00
Thomas Guillem 9c146272d0 dbus: don't spam dbus events
Wait 100ms before sending new events and drop identical events.

This fixes global Desktop freeze (happening on Gnome Shell with Debian stable)
when playing some files that update metadatas too much. This can also happen
when the playlist fail to open a lot of files in a row.
2018-02-09 09:24:04 +01:00
Thomas Guillem 52355cde73 dbus: don't send twice the same event
And don't wake up the main loop if the event was a duplication.
2018-02-09 09:23:59 +01:00
Rémi Denis-Courmont 0a74b077bc Old RC: fix assertion on "stats" 2017-12-12 20:53:01 +02:00
Rémi Denis-Courmont 3fccdd190b Old RC: do not show nonexistent sout stats 2017-12-12 20:36:01 +02:00
Rémi Denis-Courmont cc70e92424 stats: remove the lock
The containing input item lock already must be held while reading or
writing statistics, so this is redundant.
2017-12-11 21:34:14 +02:00
Hugo Beauzée-Luyssen 75de9dccf5 dbus: Add missing error check
CID #1211816
2017-11-24 16:29:29 +01:00
Hugo Beauzée-Luyssen cb96ac02ce dbus_player: Fix leaks on error
CID #1048913
2017-11-22 17:37:56 +01:00
Rémi Denis-Courmont b8a7536f85 ntservice: do not use MODULE_STRING 2017-11-18 21:41:31 +02:00
Thomas Guillem a76091852d win_msg: use vlc_alloc helper 2017-11-11 18:59:19 +01:00
Francois Cartegnie 9314bb489c vlc_arrays: split array_append in checked and w/abort 2017-10-25 12:33:02 +02:00
Rémi Denis-Courmont 82ace8beb0 xcb/globalhotkeys: fix variable shadowing 2017-09-07 22:02:20 +03:00
Thomas Guillem 0154e2485d hotkeys: remove viewpoint handling from navigation 2017-09-05 10:19:32 +02:00
Thomas Guillem d6bf647e3c actions: add vlc_actions_get_keycodes
Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2017-08-09 10:50:37 +02:00
Thomas Guillem c46cbfef3a actions: replace libvlc->p_hotkeys
Use vlc_actions_get_key_names instead

Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2017-08-09 10:48:29 +02:00
Thomas Guillem 327ecc39de actions: rename vlc_GetActionId to vlc_actions_get_id
Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2017-08-09 10:48:12 +02:00
Thomas Guillem c0d287e72f core: rename vlc_keys.h to vlc_actions.h
Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2017-08-09 10:48:01 +02:00
Thomas Guillem 324c1770eb core: rename vlc_action_t to vlc_action_id_t
Since we'll need vlc_actions_t

Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2017-08-09 10:47:56 +02:00
Thomas Guillem f832fa6870 hotkeys: fix unused warning 2017-07-25 17:55:55 +02:00
Steve Lhomme e62a4aadad hotkeys: handle viewpoint changes from the vout
Signed-off-by: Thomas Guillem <thomas@gllm.fr>
2017-07-25 16:40:51 +02:00
Thomas Guillem e61dee0091 core: move viewpoint to vlc_viewpoint.h 2017-07-25 16:40:51 +02:00
Rémi Denis-Courmont 2d40d070fd dbus: remove antilogy
This avoids bogus return-type warnings.
2017-07-23 17:26:43 +03:00
Rémi Denis-Courmont edc33fede5 globalhotleys/xcb: fix variable shadowing 2017-07-23 17:26:43 +03:00
Rémi Denis-Courmont 1ce92ecf72 oldrc: avoid shadowing 2017-07-23 17:26:43 +03:00
Rémi Denis-Courmont 3b2f515844 hotkeys: remove duplicated variable 2017-07-23 17:26:43 +03:00
Rémi Denis-Courmont f4282ec4be hotkeys: comment intended fall-throughs 2017-07-23 17:26:43 +03:00
Rémi Denis-Courmont a465a23473 hotkeys: missing break 2017-07-23 17:26:43 +03:00
Francois Cartegnie 7d49b1c033 vlc_vout: channels disambiguation 2017-06-23 14:09:20 +02:00
Francois Cartegnie 68588c1b84 vlc_arrays: add vlc_dictionary_is_empty
avoids walking every key/entry
2017-06-22 10:58:47 +02:00
David Fuhrmann d3e682d299 hotkeys: Set sub-text-scale variable on playlist level
This makes sure it outlives vout instances and is valid for the
whole playlist session.
hotkeys: Set sub-text-scale variable on playlist level

This makes sure it outlives vout instances and is valid for the
whole playlist session.
2017-06-18 22:50:21 +02:00
Rémi Denis-Courmont 05b779fb31 dbus: fix naming of multiple instances
The do-not-queue flag is necessary to ensure that the bus name is
obtained immediately or not at all. Without it, each VLC instances gets
put into the queue for the same name.

Also, failure must be checked from the return value of the function,
not (typically) the low-level error flag.
2017-06-18 18:58:25 +03:00
Rémi Denis-Courmont 2699b1d5d1 dbus: add variable to expose register bus name 2017-06-18 17:51:41 +03:00
Hugo Beauzée-Luyssen 942e24065a Revert "hotkeys: Reset scale to screen when zooming"
This reverts commit e287366ad9.
This was an invalid way of fixing #18258
Having the fullscreen state properly propagated to the vout_display
fixes the issue in a more proper way
2017-06-15 16:48:44 +02:00
Filip Roséen 7aa4bec741 playlist: playlist_NodeDelete: privatize forceful delete
Only the core should have permission to do forceful deletion of
entities.

This patch removes a mostly static, from outside of the core, argument
to playlist_NodeDelete, while also making it safer to use as it was
previously possible for anything with access to the function to delete
read-only entities.

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2017-05-21 22:20:14 +03:00
Filip Roséen d2e4278b53 control/dbus: dbus_tracklist: simplify PropertiesChangedSignal
There is no need to query all keys when we are only interested in the
presence of a single one; these changes simplify the implementation to
properly reflect the intent.

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2017-05-18 18:56:56 +03:00
Filip Roséen adc31fd144 control/dbus: dbus_root: simplify PropertiesChangedSignal
There is no need to query all keys when we are only interested in the
presence of a single one; these changes simplify the implementation to
properly reflect the intent.

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2017-05-18 18:56:56 +03:00
Filip Roséen a8a4b7fb0f control/dbus: dbus_player: clean PropertiesChangedSignal
The return-value of vlc_dictionary_all_keys is a null-terminated array
of the associated keys (on success), meaning that there is no explicit
need to query the count of keys.

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2017-05-18 18:56:56 +03:00
Rémi Denis-Courmont 4d2fb7d36f playlist: remove mode parameter from playlist_NodeAddInput() 2017-05-14 18:44:14 +03:00
Rémi Denis-Courmont f7770d42a8 dbus: use playlist_ViewPlay() instead of PLAYLIST_GO 2017-05-14 18:44:14 +03:00
Rémi Denis-Courmont 01381e2190 oldrc: use playlist_ViewPlay() 2017-05-14 18:44:13 +03:00
Rémi Denis-Courmont 0b41b45504 hotkeys: use playlist_ViewPlay(), fix aliasing
(The node parameter must be a playlist_item_t *, cannot be a void *.)
2017-05-14 18:44:13 +03:00
Rémi Denis-Courmont 0d7f4dbf06 dbus: use playlist_ViewPlay() 2017-05-14 18:44:13 +03:00
Rémi Denis-Courmont 435aecff88 playlist: use boolean for playlist_AddInput() mode parameter 2017-05-14 18:44:13 +03:00
Rémi Denis-Courmont 5d874075a1 oldrc: fix reference leak 2017-05-14 18:44:13 +03:00
Rémi Denis-Courmont e5ad757d39 playlist: use boolean for playlist_AddExt() mode parameter 2017-05-14 18:44:13 +03:00
Rémi Denis-Courmont 420f50cceb playlist: use boolean for playlist_Add() mode parameter 2017-05-14 18:44:13 +03:00
Rémi Denis-Courmont dd7616662c playlist: remove constant playlist_Add() parameter 2017-05-14 18:44:13 +03:00
Rémi Denis-Courmont 9c77c04437 playlist: allocate the root item statically
This allocates space for the root playlist item directly inside the
playlist structure. Creation of that item required a special case
anyway as it was the only item without a parent.

As a consequence, one unhandled error case is removed.
2017-05-14 18:44:13 +03:00
Hugo Beauzée-Luyssen e287366ad9 hotkeys: Reset scale to screen when zooming
Fix #18258
2017-05-10 17:26:54 +02:00
Mohammed (Shaan) Huzaifa Danish b959f4053f hotkeys: Implement reverse sub track cycling
Pressing 'v' to change the cycle track, we now use 'Alt+v' to cycle in the reverse direction.

Close #8958

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2017-05-03 22:13:51 +02:00
Thomas Guillem f7d8549c2f motion: add missing static 2017-04-11 15:18:41 +02:00
Rémi Denis-Courmont f4bb458815 Replace vlc_gc_decref() with input_item_Release() 2017-04-09 17:28:19 +03:00
Rémi Denis-Courmont fe3ffffb96 oldrc: simplify quit 2017-03-21 21:37:23 +02:00
Filip Roséen 0ad2356a5f control/globalhotkeys: xcb: fix p_sys->p_map population
As described in #18136, certain configurations end up causing a
double-free in xcb.c:Close due to the same value returned from
xcb_key_symbols_get_keycode appearing multiple times in p_sys->p_map.

The code responsible for clean-up assumes that every value refers to a
separate allocated resource, whereas Mapping potentially populates
p_sys->p_map with the same value several times.

These changes make sure that initialization vs clean-up is in harmony.

fixes: #18136

Signed-off-by: Hugo Beauzée-Luyssen <hugo@beauzee.fr>
2017-03-20 13:33:21 +01:00
Rémi Denis-Courmont bb5744f6cb dbus: use vlc_array_init() instead of vlc_array_new()
This fixes missing error tests by making them unnecessary.

This also fixes a race in remove_timeout().
2017-02-19 23:08:44 +02:00
Rémi Denis-Courmont 7ecd9271af array: fix up types in vlc_array_*()
- use size_t, ssize_t,
 - handle const types where applicable.
2017-02-19 22:58:43 +02:00
Hugo Beauzée-Luyssen 87a7952160 ntservice: Don't attempt to concatenate with an empty string 2017-02-14 15:37:40 +01:00
Hugo Beauzée-Luyssen 5605fce47c ntservice: Fix potential buffer overflow
CID #1402742
2017-02-14 15:37:40 +01:00
Hugo Beauzée-Luyssen 4deac4d605 ntservice: Fix potential leak 2017-02-14 15:37:40 +01:00
Rémi Denis-Courmont 23d17364b6 globalhotkeys/xcb: fix leak on error 2016-12-22 22:04:49 +02:00
Rémi Denis-Courmont edc3e0ba61 globalhotkeys/xcb: fix memory leaks 2016-12-22 22:04:49 +02:00
Jean-Baptiste Kempf fb9ab461aa hotkeys: increase the 360 nav sensitivity 2016-12-03 13:50:30 +01:00
Adrien Maglo 24dddc303d core: remove the 360 video viewpoint zoom
The functionality is provided by the fov parameter.

Signed-off-by: Thomas Guillem <thomas@gllm.fr>
2016-11-25 10:55:29 +01:00
Adrien Maglo cd022d9cdd hotkeys: change the FOV instead of the zoom
Signed-off-by: Thomas Guillem <thomas@gllm.fr>
2016-11-25 10:36:05 +01:00
Rémi Denis-Courmont 5111ca464b playlist: remove constant playlist_Add() parameter 2016-11-19 17:24:31 +02:00
Rémi Denis-Courmont 06f2a64ba2 playlist: remove useless intf-change object variable 2016-11-19 16:41:53 +02:00
Rémi Denis-Courmont b459e18dbf playlist: remove position parameter to playlist_Add*
This removes the insertion offset parameter to playlist_Add(),
playlist_AddExt() and playlist_AddInput().

intf_InsertItem() was the only occurrence where the offset was zero,
a side effect of how the command line is parsed backward. This is now
done explicitly with playlist_NodeAddInput().

A non-zero positive offset made no sense, since:
 - the number of children of a node can change asynchronously while the
   playlist lock,
 - the back-end asserted or triggered undefined behaviour if the offset
   was out of range.
DBus was the only occurrence of this bug (see also #17451 comment:4),
and has been fixed in an earlier change.

In all remaining call sites, the offset was PLAYLIST_END. This removes
the parameter which would otherwise constitute a useless constant.
2016-11-19 13:26:21 +02:00
Rémi Denis-Courmont 8cc1c986b8 playlist: remove constant duration parameter to playlist_AddExt() 2016-11-19 12:59:11 +02:00
Rémi Denis-Courmont 0aa7f149a5 dbus: fix racy track addition (refs #17451)
This fixes potential assertion failures. Insertion position must always
be valid.
2016-11-19 12:52:58 +02:00
Rémi Denis-Courmont 4a2f6a8194 playlist: remove APPEND and INSERT flags
They are set but never used. In practice, the (following) position
parameter determines whether the item is inserted or appended. A
positive position means insertion; PLAYLIST_END means appendment.
2016-11-19 11:59:01 +02:00
Thomas Guillem 5d48ad31e3 hotkeys: handle 360° zoom with mouse wheel 2016-11-18 10:45:39 +01:00
Thomas Guillem 5c01b5d131 hotkeys: handle the mouse events for VR/360° navigation 2016-11-18 10:45:39 +01:00
Thomas Guillem 7ef3112223 hotkeys: listen to new inputs and new vouts
Listen to playlist "input-current" to update the current input_thead_t, and
listen to input "intf-event" to update the current vout. The vout/input don't
need to be fetched when processing an action, this removes one FIXME, but this
adds more lock complexity.

This will be mainly needed for the next commit, in order to listen to mouse
events from the vout.
2016-11-18 10:45:39 +01:00
Thomas Guillem 4ad8cdba14 core: keys: add ACTION_ID_VIEWPOINT_ROLL (not bound) 2016-11-17 09:47:45 +01:00
Thomas Guillem 70ad5ae84e core: keys: add ACTIONID_VIEWPOINT_ZOOM_* 2016-11-17 09:47:45 +01:00
Thomas Guillem d68a92f55b core: keys: rename ACTIONID_FOV* to ACTIONID_VIEWPOINT_FOV* 2016-11-17 09:37:26 +01:00
Rémi Denis-Courmont 9d2aa1f9f1 playlist: remove locked parameter to playlist_AddInput() 2016-11-16 23:47:03 +02:00
Rémi Denis-Courmont b46ae2a939 playlist: remove locked parameter to playlist_AddExt() 2016-11-16 23:44:46 +02:00
Rémi Denis-Courmont 284b59b94f playlist: remove locked parameter to playlist_Add()
This is always false. For unlocked insertions, playlist_NodeAddInput()
is preferred.
2016-11-16 23:42:00 +02:00
Rémi Denis-Courmont cc67adbfdc playlist: remove constant playlist_NodeDelete() parameter 2016-11-16 20:08:52 +02:00
Rémi Denis-Courmont ce385e2711 dbus: remove write-only callback_info_t.i_node 2016-11-15 23:46:50 +02:00
Rémi Denis-Courmont 1fb88c4b35 dbus: reindent 2016-11-15 22:04:39 +02:00
Rémi Denis-Courmont 014d77b76e dbus: use playlist item IDs rather input item IDs 2016-11-15 22:04:39 +02:00
Rémi Denis-Courmont c90fc91a0f dbus: simplify seek signal sending 2016-11-15 22:04:39 +02:00
Steve Lhomme 1e4c227201 hotkeys: new hotkeys to change the viewpoint in 360° videos
yaw: Left/Right (same a DVD/BR nav)
pitch: Up/Down (same a DVD/BR nav)
fov: Page Up/Page Down

Signed-off-by: Thomas Guillem <thomas@gllm.fr>
2016-11-15 18:13:46 +01:00
Rémi Denis-Courmont f0573e676b playlist: remove phony playlist item pointers 2016-11-14 23:52:04 +02:00
Filip Roséen 02dc376754 control/oldrc: limit scope of iteration variables
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2016-10-13 18:34:42 +02:00
Filip Roséen 558d11ba69 control/motionlib: remove trailing whitespace
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2016-10-13 18:34:42 +02:00
Rémi Denis-Courmont c240692f0b Common structure for VLC common object members, document 2016-06-18 18:01:32 +03:00
Jean-Baptiste Kempf 21fa1cb48b configure: provide a HAVE_WIN32_DESKTOP 2016-05-16 11:45:27 +02:00
Jean-Baptiste Kempf f365b047ec WinRT: don't compile the NTservice 2016-05-16 10:48:35 +02:00
Rémi Denis-Courmont 8f2e1e57cf Use vlc_close() 2016-04-22 00:11:43 +03:00
Hugo Beauzée-Luyssen ac3c74f6e4 control: oldrc: Fix build on winrt 2016-04-18 15:09:26 +02:00
Hugo Beauzée-Luyssen 7211424f16 control: dummy: Fix winstore build 2016-04-18 09:56:52 +02:00
Filip Roséen e3cbd73980 D-Bus control: fixed include-guards
* renamed include-guards to fix issues with reserved identifiers
  * replaced comments at `#endif` corresponding to include-guards

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2016-02-22 11:59:18 +01:00
Rémi Denis-Courmont 933424d7ed vcdx: remove unmaintained module 2016-01-07 23:30:19 +02:00
Rémi Denis-Courmont 2850821ad7 variables: voidify var_TriggerCallback()
The function can only fail if the named variable does not exist. The
only case where the error was actually checked was after another check
that the variable exists (Old RC).
2015-11-28 12:18:15 +02:00
Rémi Denis-Courmont 43a771c119 old: use type-safe variable setter/getter 2015-11-28 12:15:16 +02:00
Jean-Baptiste Kempf 5dafc001bb Modules: Remove tabs in source code 2015-11-05 10:05:20 +01:00
Francois Cartegnie 2e76eb8173 add spu text scaling actions 2015-09-07 00:12:31 +02:00
Rémi Denis-Courmont d7a88fe038 url: remove vlc_UrlParse() option parameter
That parameter assumed that the query was part of the path. However it
is not, which leads to invalid host name, and eventually failure when
the path is missing. In practice, passing any value other than '?' as
separator would not work properly.

Remaining vlc_UrlParse() call sites without the option separator do not
support query at the protocol level anyway, so they are unaffected by the
change.

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2015-08-27 21:35:34 +03:00
Rémi Denis-Courmont a3a6a95aad net_Read: remove no longer used waitall parameter
It was always either true or unused. Note that when the buffer length
is 1 byte, waitall had no effects.

net_Read() and net_Write() are now symmetric.
2015-07-01 19:17:54 +03:00
Rémi Denis-Courmont ed69f1dcc8 oldrc: use input "state" variable instead of b_dead 2015-06-05 22:33:09 +03:00
Rémi Denis-Courmont 5885e88a76 oldrc: fix reading from standard input 2015-06-04 23:38:05 +03:00
Rémi Denis-Courmont d39ba9a05c input: switch spu and audio delay variables to integer type 2015-05-22 22:14:39 +03:00
Rémi Denis-Courmont 4286e34200 input: change time-offset from time to integer type 2015-05-22 22:14:39 +03:00
Rémi Denis-Courmont ce80ca38a7 input: change time and length variable to integer 2015-05-22 22:14:37 +03:00
Rémi Denis-Courmont c0cdab15a4 Remove no longer used net_Read() argument 2015-05-12 22:25:11 +03:00
Rémi Denis-Courmont 9b629ed21d Remove no longer used net_vaPrintf() argument 2015-05-12 22:25:11 +03:00
Jean-Baptiste Kempf 977ed86ca8 Use "IP" for IP address 2015-04-14 22:56:42 +02:00
Rémi Denis-Courmont a2110274cb oldrc: rename the source file too 2015-03-30 18:00:16 +03:00
Rémi Denis-Courmont 56220f8612 vlc_plugin: fix non-LGPL plugins meta infos 2015-03-21 14:18:20 +02:00
Rémi Denis-Courmont 2d6e21de83 playlist: remove activity callback in favor of input-current 2015-03-19 20:11:40 +02:00
Zoran Turalija 5e6b6558c6 gestures: fix: allow gesture to be triggered
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2015-03-08 23:47:57 +01:00
Rémi Denis-Courmont f3398a2741 control: move CONSOLE_INTRO_MSG to a private header 2015-03-02 22:45:12 +02:00
Rémi Denis-Courmont 3c6db86cf6 oldrc: only invoke console intro message where applicable 2015-03-02 22:45:12 +02:00
Rémi Denis-Courmont 80d88b05f2 Mark unreachable code on GCC even if NDEBUG
This might suppress some warnings (and very slightly reduce code size)
when assertions are disabled. Not that I particularly like to create
VLC-specific macros.
2015-02-18 17:52:52 +02:00
Rémi Denis-Courmont 5260788250 control: remove Makefile recursion 2015-02-10 23:12:26 +02:00
Rémi Denis-Courmont a80fe1ea5e control: clean up build rules 2015-02-10 23:12:26 +02:00
Rémi Denis-Courmont bdcdf97054 input: merge ABORT and DEAD events 2015-02-05 22:30:36 +02:00
Rémi Denis-Courmont 43b06eed8e playlist: use the new playlist_Pause() where appropriate
This fixes corking especially.
2014-12-15 19:22:46 +02:00
Rémi Denis-Courmont a437fe543c playlist: use playlist_TogglePause() directly, fix minor races
This function already starts playback if stopped (and as far as I know
it always has).
2014-12-15 19:21:58 +02:00
Rémi Denis-Courmont c5cf779303 playlist: use playlist_Play() directly, fix minor races
This function already checks if the playlist is running internally,
in which case it has no effects.
2014-12-15 19:20:29 +02:00
Rémi Denis-Courmont 522604203a playlist: rename playlist_Pause() to playlist_TogglePause()
The behaviour is unchanged:
 - if stopped: starts playing,
 - if playing: pauses playing,
 - if paused: resumes playing.
2014-12-15 19:09:16 +02:00
Jean-Baptiste Kempf 31d8cc6476 Win32: don't build WM_* based plugins under WinRT 2014-11-21 15:19:50 +01:00
Hugo Beauzée-Luyssen 260d31fa7b rc: Fix invalid returned value 2014-10-24 17:09:47 +02:00
Rémi Denis-Courmont 32486e651c variables: remove VLC_VAR_GETLIST (same as VLC_VAR_GETCHOICES) 2014-10-23 22:11:49 +03:00
Rémi Denis-Courmont 8a20203939 hotkeys: use "zoom" rather than "scale" (like the GUI do) 2014-10-23 21:04:27 +03:00
Rémi Denis-Courmont 20729b41f7 gestures: cosmetic 2014-09-01 18:54:41 +03:00
Rémi Denis-Courmont 3d663c8e3b gestures: avoid undefined negative shift 2014-09-01 18:54:41 +03:00
Felix Paul Kühne 901d25addc unimotion: fix warning 2014-08-31 23:50:13 +02:00
Rémi Denis-Courmont e2da5c14f6 dbus: avoid invalid zero-size array 2014-08-20 20:58:16 +03:00
Rémi Denis-Courmont d760499fd9 netsync: check received packet sizes 2014-08-18 20:43:13 +03:00
Rémi Denis-Courmont 228182fe9c dbus: fix timeout handling
- Remove useless pointer back to DBusTimeout.
 - Fix memory error handling.
 - Fix race in accessing timer data.
 - Fix integer overflow.
 - Follow libdbus rules for retrieving time-out interval upon toggle.
 - Simplify expiration computations.
2014-08-18 20:29:36 +03:00
Rémi Denis-Courmont efa6a6fe9c gestures: fix callback leak and missing locking 2014-08-16 15:48:57 +03:00
Rémi Denis-Courmont cc69b31845 netsync: fix and simplify dead input handling (fixes #5426) 2014-08-16 15:48:57 +03:00
Rémi Denis-Courmont 3c2c9364a1 Handle NULL value in "input-current" callback 2014-08-16 15:48:57 +03:00
Rémi Denis-Courmont 67aa058beb dbus: fix file descriptors leak 2014-08-16 13:48:17 +03:00
Rémi Denis-Courmont 078317de42 dbus: register only one MPRIS bus name (fixes #10301) 2014-08-16 13:44:37 +03:00
Rémi Denis-Courmont d32c36dc11 dbus: register object path before bus names
This fixes a race condition where the player was visible on the bus
with the MPRIS name, but did not implement MPRIS.
2014-08-16 13:37:23 +03:00
Rémi Denis-Courmont 3cd098faaf netsync: fix stale pointer on error 2014-08-16 13:11:09 +03:00
Hannes Domani 09cc30dff2 oldrc: fix thread-cancellation on windows (fixes #10483)
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2014-08-16 10:27:10 +03:00
Rémi Denis-Courmont 5adb3308b8 Remove vlc_input.h from vlc_playlist.h 2014-08-15 23:00:13 +03:00
Rémi Denis-Courmont 07d3ca8dfd hotkeys: stick to single precision 2014-08-13 23:22:43 +03:00
Adrian Haensler 69d6f2ab18 hotkeys: new hotkey for toggling subtitles
A subtitle track chosen by hotkey "v" is remembered in variable "spu-choice".
The hotkey "Shift+v" toggles subtitle visibility.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2014-06-14 13:25:59 +02:00
Rémi Denis-Courmont 19da251907 dbus: remove evil intractable macro, fix memory leak 2014-04-24 21:06:29 +03:00
Rémi Denis-Courmont 37f6e51311 dbus: memory leak 2014-04-23 23:37:35 +03:00
Rémi Denis-Courmont 9ddb7984a4 dbus: fix undefined zero-size arrays 2014-04-14 23:40:31 +03:00
Rémi Denis-Courmont a3be08a370 motionlib: fix potential file descriptor leak, set close-on-exec 2014-04-12 17:02:44 +03:00
Rémi Denis-Courmont dd7b6ad867 Old RC: inverted logic (fixes #11052) 2014-03-31 19:51:46 +03:00
Rémi Denis-Courmont f319b959d1 msw: collect files in a single directory (fixes #10900) 2014-03-20 20:50:40 +02:00
Jean-Baptiste Kempf 663877d854 Win32: Do not assert on non-recognized touch events
Sometimes GF_INERTIA is caught too, for example
2014-03-20 19:30:01 +01:00
Rémi Denis-Courmont 555e043242 winmsg: fix name 2014-03-12 19:15:37 +02:00
Ludovic Fauvet 20c8e19ed3 Add Win32 gestures helper
This is a helper to take action on touchscreens on Windows 7 or later
It uses the braindead WM_GESTURE API and supports volume, seek (1 and 2
fingers), play/pause (2finger touch) and fullscreen (zoom gesture)

The API is simple so other UI element can use it, notably Qt and the
vouts

This has been edited by jb too

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2014-02-16 23:51:13 +01:00
Rémi Denis-Courmont c33e62ce48 RC: remove last stray reference to the menu command (fixes #10539) 2014-02-02 13:21:37 +02:00
Rémi Denis-Courmont 0991948a3e Old RC: remove reference to former menu command (fixes #10539) 2014-02-01 18:55:10 +02:00
Felix Abecassis 9f7bfd93e3 hotkeys: fullscreen state of the vout should have precedence over fullscreen state of the playlist
Double clicking to toggle to fullscreen mode does not trigger this code
path since 7b8083d228. The state of the playlist was therefore not in
sync with the vout. Pressing the fullscreen hotkey caused the state of
the playlist to be used to set the state of the vout, thus causing the bug.

Close #10433.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2014-01-28 20:20:57 +01:00
Rémi Denis-Courmont 11405d4de4 interface: create the playlist first and use it as parent 2014-01-08 00:07:50 +02:00
Rémi Denis-Courmont 36ac118c4c win32: move single instance back-end to separate interface 2014-01-08 00:07:50 +02:00
Rémi Denis-Courmont 2f846d8c8e hotkeys: fix wall-paper toggling 2014-01-05 12:21:22 +02:00
Rémi Denis-Courmont 4a50968e61 motion: use pl_CurrentItem() 2014-01-03 00:23:03 +02:00
Rémi Denis-Courmont 27da836685 dbus: use pl_CurrentInput() 2014-01-01 20:55:41 +02:00
Rémi Denis-Courmont c4199ab677 Remove inconsistently used HAVE_UNISTD_H 2013-12-29 16:15:46 +02:00
Rémi Denis-Courmont a63ffa2b56 RC (old): use vlc_strerror_c() 2013-12-29 15:59:58 +02:00
Rémi Denis-Courmont 7308be6b58 D-Bus: use vlc_strerror_c() 2013-12-29 15:59:57 +02:00
Rémi Duraffort 5cc6eadcf8 dbus: fix memory leaks (cid #1048913) 2013-12-11 18:49:42 +01:00
Maxim Bublis f0b3483323 Fixed warnings on duplicate const modifiers.
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2013-11-18 21:04:45 +02:00
Mirsal a9f899a33e dbus: Fix the MPRIS version in the header comments
Change the mpris version to 2.2 as VLC implements it.
2013-11-13 10:32:05 +01:00
Rémi Denis-Courmont be6723352a XCB/globalhostkeys: add support for meta modifier 2013-11-06 22:30:10 +02:00
Mirsal Ennaime af1a7a9501 dbus: Fix copy-paste error
(Coverity report 1100848)
2013-10-23 00:17:09 +02:00
Rémi Denis-Courmont 4dd7f02c16 hotkeys: show intended rather than current mute status 2013-10-22 20:15:23 +03:00
Rémi Denis-Courmont 593fa45661 dbus: fix volume setting (fix #9628) 2013-10-09 20:57:04 +03:00
Rafaël Carré 0b896ac15a Fix linking of motion and rotate modules
142e288b17 set LDFLAGS conditionally
Be sure that it is always set and concatenate the DARWIN flags
2013-09-21 20:21:39 +02:00
Felix Paul Kühne 142e288b17 macosx: fix linking the motion and rotate modules
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2013-09-19 15:11:58 +02:00
Rémi Denis-Courmont c1452fef22 xcb: simplify build rules 2013-09-16 20:12:30 +03:00
Rémi Denis-Courmont bca1bc25f2 motionlib: build only once (refs #9367) 2013-09-16 18:54:36 +03:00
Rémi Denis-Courmont 98cea7a2a2 modules: remove VLC-specific AM_LIBADD, simplify 2013-09-16 18:54:31 +03:00
Rémi Denis-Courmont 20cdb051ac modules: simplify CPPFLAGS & CFLAGS 2013-09-16 18:54:31 +03:00
Rémi Denis-Courmont e67cf044cc modules: use different directory prefixes for each plugins subdirectory
This is just a step toward less recursion.
2013-09-16 18:54:31 +03:00
Rémi Denis-Courmont 6ef248d651 globalhotkeys: use different names for Win32 and XCB targets
This works around an automake limitation with multiple directory
prefixes.
2013-09-15 20:32:39 +03:00
Rémi Denis-Courmont 640d0794a0 modules: factor Makefile statement 2013-09-14 19:29:35 +03:00
Rémi Denis-Courmont d3bd87aaf3 Add subdir-objects automake option where appropriate
Makes version 1.14 happy.
2013-09-05 22:20:01 +03:00
Rémi Duraffort f393ebdfb8 hotkeys: Fix test (was always true) 2013-08-09 10:24:02 +02:00
Rafaël Carré 7e3c4b6648 Version all plugins when building for Windows
Refs #9108
2013-08-01 17:32:11 +02:00
Rémi Duraffort 9632f52e4f Fix wrong test (cid #1049310) 2013-07-22 19:34:35 +02:00
Rémi Duraffort eb73eec87c rc: fix previous commit (wrong C&P) 2013-07-13 10:06:02 +02:00
Rémi Duraffort 9f895cdaec Fix potential double free (#cid 403064) 2013-07-13 08:24:26 +02:00
Edward Wang 06005e87c7 xcb: fix some memory leaks
According to xcb docs, we are responsible for freeing this memory.

Signed-off-by: Rafaël Carré <funman@videolan.org>
2013-06-25 01:57:33 +02:00
Rafaël Carré 6d53362001 Use _WIN32 rather than WIN32 (same for WIN64)
http://msdn.microsoft.com/en-us/library/b0084kay(v=vs.80).aspx only
mentions the _ prefixed variable.

gcc will always define the _ prefixed variable, like Visual Studio.
The prefixless one is defined in some language standards, e.g. gnu99
but not c99.
2013-06-05 16:06:10 +02:00
Zoran Turalija c751120fb5 hotkeys: Added OSD messages for toggle loop tri-state playlist action.
Closes ticket #7933

Based on "loop" part of John French patch:

    http://patches.videolan.org/patch/1071/

Modified-and-...
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2013-04-23 22:55:55 +03:00
Zoran Turalija 0dc62cd19d hotkeys: Added OSD messages for toggle repeat playlist action.
Resolves part of ticket #7933

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2013-04-23 22:55:03 +03:00
Rémi Denis-Courmont 548a2f6933 Old RC: remove object commands 2013-04-23 22:45:42 +03:00
Jean-Baptiste Kempf 105c1cfecd Hotkeys: strings simplifications 2013-04-21 17:08:23 +02:00
Zoran Turalija e021989e80 hotkeys: Bookmark subtitle timestamp only if it exists and is enabled.
In ACTIONID_SUBSYNC_MARKSUB, do not bookmark subtitle timestamp if
there is no subtitle, or if subtitle has been currently disabled.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2013-04-21 17:05:27 +02:00
Zoran Turalija 251fdaddb2 hotkeys: Change subtitle position only if it exists and is enabled.
In ACTIONID_SUBPOS_UP/DOWN, do not change subtitle position if there
is no subtitle, or if subtitle has been currently disabled.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2013-04-15 11:28:37 +02:00
Zoran Turalija b430b4c248 hotkeys: Delay subtitle track only if it exists and is enabled.
In ACTIONID_SUBDELAY_UP/DOWN, do not delay subtitle if there is none,
or if subtitle has been currently disabled.

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2013-04-15 11:23:11 +02:00
Pascal Thomet f7211d5efa Subsync: added an easier way to sync subtitles
Added the following shortcuts (and made them configurable):
 - Shift-H: sets a timestamp bookmark on the audio
 - Shift-J: sets a timestamp bookmark on the subtitle
 - Shift-K: corrects the delay between both bookmarks
 - Command-Shift-K: resets the delay

See http://forum.videolan.org/viewtopic.php?f=7&t=109641 for an
illustration of a possible use

Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2013-04-13 20:09:54 +02:00
Martin Zeman ddfbadf345 Added a hotkey for playlist deletion.
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2013-04-13 19:41:12 +02:00
Zoran Turalija e8dc8779bf Add hotkeys to cycle through previous/next program SIDs.
Change "cycle through program SIDs" to support cycle both ways (prev/next).
With this commit, it is possible e.g. to quickly change between neighbor
program SIDs back and forth in multi-program stream like DVB streams using
default x/Shift+x keys.

Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>
2013-03-28 18:26:13 +02:00
Rémi Denis-Courmont c1a7028265 Old RC: fix exit 2013-03-26 18:10:32 +02:00
Rémi Denis-Courmont 4e63804875 Old RC: cleanup use of p_sys
Also do not check that playlist is non-NULL (always true).
2013-03-26 18:10:13 +02:00
Rémi Denis-Courmont 136355acb7 Old RC: remove cargo-cultivated input state checks 2013-03-25 21:53:27 +02:00
Rémi Denis-Courmont e865945bd8 Old RC: remove tautology 2013-03-25 20:17:52 +02:00
Rémi Denis-Courmont 28c44e4f97 lirc: remove tautology
(Code is suspicious though.)
2013-03-25 20:17:35 +02:00
Edward Wang 9cd6df73b1 Correct widespread misuse of the word 'subtitle'
Subtitle is the adjective describing what kind of text. So "subtitle text" is an adjective phrase describing what kind of encoding.

For example, we don't listen to "audios tracks", program "videos codecs", or open "playlists files". Therefore, use the correct form of the word subtitle for the context.

Signed-off-by: Felix Paul Kühne <fkuehne@videolan.org>
2013-03-23 17:50:21 +01:00
Mirsal Ennaime 01b2d9f038 dbus: Fix handling of input events and remove memleaks
Correctly handle the INPUT_EVENT_ITEM_META and INPUT_EVENT_ITEM_META
instead of skipping the whole event processing code without even freeing
the callback_info_t data structure.

Closes: #8285
2013-03-10 03:54:55 +01:00
Ludovic Fauvet 8775d0d7f1 Gestures: use left button, by default
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2013-02-07 19:55:12 +01:00
Ludovic Fauvet be93074958 Gestures: use the proper event name
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
2013-02-07 19:47:10 +01:00
Mirsal Ennaime cdc85689a1 dbus: Oops, abandon the correct container on error paths 2013-02-07 04:18:12 +01:00
Mirsal Ennaime b1bb9b5436 dbus: Add another memory allocation failure check 2013-02-07 03:55:07 +01:00
Mirsal Ennaime 56180db3de dbus: Add memory allocation failure check 2013-02-06 15:16:26 +01:00
Mirsal Ennaime 018ea79787 dbus: Add missing memory allocation failure handling
Handle memory allocation failures when sending the PropertyChanged
signal in the TrackList interface implementation.
2013-02-05 13:33:36 +01:00
Mirsal Ennaime 57a0261eda dbus: Remove useless comment 2013-02-05 13:33:36 +01:00
Mirsal Ennaime 424d68f848 dbus: Fix memleaks on error paths 2013-02-05 13:33:36 +01:00
Rémi Denis-Courmont c69ad41a68 hotkeys: use only one channel for sliders
We don't display both sliders at once anyway.
2013-02-01 18:30:38 +02:00
Rémi Denis-Courmont 007607082f hotkeys: put all text on the default SPU channel
Never more than one piece of text is displayed at a time anyway.
Also simplify format string handling and use single precision maths.
2013-02-01 18:25:21 +02:00
Rémi Denis-Courmont 8c4e42a3d9 hotkeys: implement navigation actions 2013-02-01 17:55:00 +02:00
Rémi Denis-Courmont 5dc612beb4 hotkeys: remove special key event 2013-01-31 23:25:30 +02:00
Rémi Denis-Courmont 812836afe8 hotkeys: add context menu action 2013-01-31 23:25:30 +02:00
Rémi Denis-Courmont d83927d402 hotkeys: map mouse wheel actions in core 2013-01-31 23:25:30 +02:00
Rémi Denis-Courmont a0cb1c29ce hotkeys: move mouse wheel setting to core with other hotkey stuff 2013-01-31 23:25:30 +02:00
Rémi Denis-Courmont 03c911f342 Useless #includes 2013-01-31 19:32:56 +02:00
Rémi Denis-Courmont e715fddb80 Old RC: remove non-working menu command 2013-01-31 19:11:39 +02:00
Rémi Denis-Courmont e1f4d89eff LIRC: remove non-working menu 2013-01-31 19:11:39 +02:00
Rémi Denis-Courmont d66f3ddc20 hotkeys: remove unused OSD menu actions 2013-01-31 19:11:34 +02:00
Rémi Denis-Courmont 6dd33dd12b hotkeys: reorder the Big Switch and remove some useless checks 2013-01-30 20:23:31 +02:00
Alex Merry de67a476d7 dbus: Add CanGoNext/Previous
These are required by the spec.  We just set them to true, to match the
fact that the buttons on the main interface are never disabled.

Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-30 07:26:01 +01:00
Alex Merry a8fd6d9584 Add Properties.GetAll support to all D-Bus interfaces
Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-30 07:03:42 +01:00
Alex Merry 6ae4c72da0 dbus: Standardise property getters
There was a lot of repeated code, some of which properly checked return
values and some of which didn't.  This is all replaced and folded into
the GetProperty function of each interface.

A side-effect is that it should be more efficient (we only check the
interface argument once instead of once for each property, and there
should be a smaller overall code size).

Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-29 17:11:55 +01:00
Alex Merry 3aa9a4adb0 dbus: Separate out property marshalling code in D-Bus interfaces
Pull out code to marshal the various properties into separate functions
(and make sure the return type of those functions is int).  This is in
preparation for adding org.freedesktop.DBus.Properties.GetAll support.

Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-29 16:35:23 +01:00
Alex Merry 52903263c8 dbus: Standardise property marshalling for PropertiesChanged signal
Re-use the AddProperty method (used in GetAllProperties) and use macros
to reduce repetition of code.  Now all the calls should be
error-checked.

Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-29 15:19:51 +01:00
Mirsal Ennaime 3ed48e03b8 dbus: Fix code style and add missing decref on error path
* Add missing call to vlc_object_release() in MarshalMetadata
 * Separate code paths with empty lines
 * Fix bracket position in if blocks
2013-01-29 14:54:29 +01:00
Alex Merry 5460e18e20 Fix Metadata marshalling when sending the PropertiesChanged signal
VLC was getting kicked from the D-Bus when a track was stopped, because
it was generating invalid data on the wire when sending the
PropertiesChanged signal for the Metadata property.

The issue was that if there was now no current track, GetInputMeta would
never be called and the the variant would never be populated with the
"a{sv}" structure that the call to dbus_message_iter_open_container
claimed it would be.

We now share the code that GetProperties used, which dealt with this
correctly, although now both use CurrentInput (which is what the signal
previously used) instead of CurrentPlayingItem (which is what
GetProperties previously used).

Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-29 14:36:54 +01:00
Alex Merry 8f754d8715 Fix Rate property on org.mpris.MediaPlayer2.Player
Rate should never be 0.0 (according to the spec), so we pick a sensible
default when we do not have a current track: 1.0.

Also, when the current item changes, the Rate may also change.  So add
it to the PropertiesChanged signal just to be sure.

Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-28 21:28:52 +01:00
Alex Merry ad8039e3e3 Fix MPRIS2 metadata entry types
Several of these entries, such as xesam:artist, should be lists of
strings, not strings.

Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-28 21:10:28 +01:00
Alex Merry 930cae6d52 Add Fullscreen property to GetAllProperties on DBus root interface
Previously, Fullscreen could be requested via
org.freedesktop.DBus.Properties.Get, but would not be returned by
org.freedesktop.DBus.Properties.GetAll.

Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-28 17:51:31 +01:00
Alex Merry 119aa810f8 Move helpers for GetAllProperties into dbus.c
This is in preparation for implementing GetAllProperties for the player
and tracklist interfaces.

Signed-off-by: Mirsal Ennaime <mirsal@videolan.org>
2013-01-28 17:39:08 +01:00
Rafaël Carré 7997896350 oldrc: fix "playlist" and "snapshot" 2013-01-25 03:31:35 +01:00
Rémi Denis-Courmont 8385a59f5a Old RC: use audio output device functions and clean up 2013-01-15 19:33:17 +02:00
Jean-Baptiste Kempf be719e08c1 NTservice: force use of ANSI versions of APIs 2013-01-15 00:32:49 +01:00
Rémi Denis-Courmont 6399242329 hotkeys: use aout_DeviceGet() and aout_DevicesList() 2013-01-14 19:41:05 +02:00