Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.5:Update
gnome-music
0002-gnome-music-revert-from-future-import-anno...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0002-gnome-music-revert-from-future-import-annotations.patch of Package gnome-music
diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/coremodel.py gnome-music-41.1.new/gnomemusic/coremodel.py --- gnome-music-41.1.old/gnomemusic/coremodel.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/coremodel.py 2023-01-03 17:38:52.135035434 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations from typing import Optional, Union import typing @@ -78,7 +77,7 @@ _recent_size = 21 - def __init__(self, application: Application) -> None: + def __init__(self, application: 'Application') -> None: """Initiate the CoreModel object :param Application application: The Application instance to use diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/coresong.py gnome-music-41.1.new/gnomemusic/coresong.py --- gnome-music-41.1.old/gnomemusic/coresong.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/coresong.py 2023-01-03 17:38:52.135035434 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations from enum import IntEnum from random import randint from typing import Optional @@ -67,7 +66,7 @@ FAILED: int = 2 SUCCEEDED: int = 3 - def __init__(self, application: Application, media: Grl.Media) -> None: + def __init__(self, application: 'Application', media: Grl.Media) -> None: """Initiate the CoreSong object :param Application application: The application object diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/griloartqueue.py gnome-music-41.1.new/gnomemusic/griloartqueue.py --- gnome-music-41.1.old/gnomemusic/griloartqueue.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/griloartqueue.py 2023-01-03 19:02:28.490024940 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations from typing import Dict, List, Union import typing @@ -47,10 +46,10 @@ __gtype_name__ = "GriloArtQueue" - _queue: Dict[CoreObject, CoreObjectType] = {} - _active_queue: List[CoreObject] = [] + _queue: Dict['CoreObject', CoreObjectType] = {} + _active_queue: List['CoreObject'] = [] - def __init__(self, application: Application) -> None: + def __init__(self, application: 'Application') -> None: """Initialize GriloArtQueue :param Application application: The application instance @@ -62,7 +61,7 @@ self._timeout_id = 0 def queue( - self, coreobject: CoreObject, + self, coreobject: 'CoreObject', coreobjecttype: CoreObjectType) -> None: """Queue Grilo art lookup for the coreobject @@ -99,6 +98,6 @@ return GLib.SOURCE_CONTINUE def _on_async_finished( - self, storeart: StoreArt, coreobject: CoreObject) -> None: + self, storeart: StoreArt, coreobject: 'CoreObject') -> None: if coreobject in self._active_queue: self._active_queue.remove(coreobject) diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/grilowrappers/grltrackerwrapper.py gnome-music-41.1.new/gnomemusic/grilowrappers/grltrackerwrapper.py --- gnome-music-41.1.old/gnomemusic/grilowrappers/grltrackerwrapper.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/grilowrappers/grltrackerwrapper.py 2023-01-03 19:16:07.803084019 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations from typing import Callable, Dict, List, Optional import typing @@ -95,7 +94,7 @@ ] def __init__( - self, source: Grl.Source, application: Application, + self, source: Grl.Source, application: 'Application', tracker_wrapper: TrackerWrapper) -> None: """Initialize the Tracker wrapper @@ -1203,7 +1202,7 @@ return query - def get_song_art(self, coresong: CoreSong, storeart: StoreArt) -> None: + def get_song_art(self, coresong: CoreSong, storeart: 'StoreArt') -> None: """Retrieve song art for the given CoreSong Since MediaArt does not really support per-song art this @@ -1245,7 +1244,7 @@ query, self._METADATA_THUMBNAIL_KEYS, self._full_options_lprio, art_retrieved_cb) - def get_album_art(self, corealbum: CoreAlbum, storeart: StoreArt) -> None: + def get_album_art(self, corealbum: CoreAlbum, storeart: 'StoreArt') -> None: """Retrieve album art for the given CoreAlbum :param CoreAlbum corealbum: CoreAlbum to get art for @@ -1277,7 +1276,7 @@ art_retrieved_cb) def get_artist_art( - self, coreartist: CoreArtist, storeart: StoreArt) -> None: + self, coreartist: CoreArtist, storeart: 'StoreArt') -> None: """Retrieve artist art for the given CoreArtist This retrieves art through Grilo online services only. diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/gstplayer.py gnome-music-41.1.new/gnomemusic/gstplayer.py --- gnome-music-41.1.old/gnomemusic/gstplayer.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/gstplayer.py 2023-01-03 17:38:52.138368951 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations from typing import List, Optional from enum import IntEnum import typing @@ -59,7 +58,7 @@ "stream-start": (GObject.SignalFlags.RUN_FIRST, None, ()) } - def __init__(self, application: Application) -> None: + def __init__(self, application: 'Application') -> None: """Initialize the GStreamer player :param Application application: Application object diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/views/searchview.py gnome-music-41.1.new/gnomemusic/views/searchview.py --- gnome-music-41.1.old/gnomemusic/views/searchview.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/views/searchview.py 2023-01-03 17:38:52.138368951 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations from enum import IntEnum from gettext import gettext as _ from typing import Optional @@ -82,7 +81,7 @@ _view_all_albums = Gtk.Template.Child() _view_all_artists = Gtk.Template.Child() - def __init__(self, application: Application) -> None: + def __init__(self, application: 'Application') -> None: """Initialize SearchView :param GtkApplication application: The Application object @@ -156,7 +155,7 @@ return False - def _create_song_widget(self, coresong: CoreSong) -> Gtk.ListBoxRow: + def _create_song_widget(self, coresong: 'CoreSong') -> Gtk.ListBoxRow: song_widget = SongWidget(coresong, False, True) song_widget.props.show_song_number = False song_widget.props.menu = SongWidgetMenu( diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/widgets/albumwidget.py gnome-music-41.1.new/gnomemusic/widgets/albumwidget.py --- gnome-music-41.1.old/gnomemusic/widgets/albumwidget.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/widgets/albumwidget.py 2023-01-03 17:38:52.138368951 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations from gettext import ngettext from typing import Optional, Union import typing @@ -65,7 +64,7 @@ selection_mode = GObject.Property(type=bool, default=False) show_artist_label = GObject.Property(type=bool, default=True) - def __init__(self, application: Application) -> None: + def __init__(self, application: 'Application') -> None: """Initialize the AlbumWidget. :param GtkApplication application: The application object @@ -162,7 +161,7 @@ @GObject.Property( type=object, default=None, flags=GObject.ParamFlags.READWRITE) - def active_coreobject(self) -> Optional[Union[CoreAlbum, CoreArtist]]: + def active_coreobject(self) -> Optional[Union[CoreAlbum, 'CoreArtist']]: """Get the current CoreObject. active_coreobject is used to set the Player playlist @@ -181,14 +180,14 @@ @active_coreobject.setter # type:ignore def active_coreobject( - self, coreobject: Union[CoreAlbum, CoreArtist]) -> None: + self, coreobject: Union[CoreAlbum, 'CoreArtist']) -> None: """Update CoreOject used for AlbumWidget. :param CoreAlbum corealbum: The CoreAlbum object """ self._active_coreobject = coreobject - def _create_widget(self, disc: CoreDisc) -> DiscBox: + def _create_widget(self, disc: 'CoreDisc') -> DiscBox: disc_box = DiscBox(self._application, self._corealbum, disc) disc_box.connect('song-activated', self._song_activated) @@ -244,7 +243,7 @@ self._released_label.props.label = label - def _play(self, coresong: Optional[CoreSong] = None) -> None: + def _play(self, coresong: Optional['CoreSong'] = None) -> None: signal_id = 0 def _on_playlist_loaded(klass, playlist_type): @@ -256,7 +255,7 @@ self._coremodel.props.active_core_object = self.props.active_coreobject def _song_activated( - self, widget: Gtk.Widget, song_widget: SongWidget) -> None: + self, widget: Gtk.Widget, song_widget: 'SongWidget') -> None: if self.props.selection_mode: song_widget.props.selected = not song_widget.props.selected return diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/widgets/artistalbumswidget.py gnome-music-41.1.new/gnomemusic/widgets/artistalbumswidget.py --- gnome-music-41.1.old/gnomemusic/widgets/artistalbumswidget.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/widgets/artistalbumswidget.py 2023-01-03 17:38:52.138368951 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations import typing from gi.repository import GObject, Gtk, Handy @@ -49,7 +48,7 @@ selection_mode = GObject.Property(type=bool, default=False) def __init__( - self, coreartist: CoreArtist, application: Application) -> None: + self, coreartist: 'CoreArtist', application: 'Application') -> None: """Initialize the ArtistAlbumsWidget :param CoreArtist coreartist: The CoreArtist object diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/widgets/disclistboxwidget.py gnome-music-41.1.new/gnomemusic/widgets/disclistboxwidget.py --- gnome-music-41.1.old/gnomemusic/widgets/disclistboxwidget.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/widgets/disclistboxwidget.py 2023-01-03 17:38:52.138368951 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations from gettext import gettext as _ import typing @@ -57,8 +56,8 @@ show_disc_label = GObject.Property(type=bool, default=False) def __init__( - self, application: Application, corealbum: CoreAlbum, - coredisc: CoreDisc) -> None: + self, application: 'Application', corealbum: 'CoreAlbum', + coredisc: 'CoreDisc') -> None: """Initialize :param Application coredisc: The Application object diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/widgets/playlistswidget.py gnome-music-41.1.new/gnomemusic/widgets/playlistswidget.py --- gnome-music-41.1.old/gnomemusic/widgets/playlistswidget.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/widgets/playlistswidget.py 2023-01-03 17:38:52.138368951 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations import typing from gi.repository import Gdk, GObject, Gtk @@ -48,8 +47,8 @@ _songs_list_ctrlr = Gtk.Template.Child() def __init__( - self, application: Application, - playlists_view: PlaylistsView) -> None: + self, application: 'Application', + playlists_view: 'PlaylistsView') -> None: """Initialize the PlaylistsWidget. :param Application application: The application object @@ -86,7 +85,7 @@ self._pl_ctrls.props.playlist = playlist def _create_song_widget( - self, coresong: CoreSong, playlist: Playlist) -> Gtk.ListBoxRow: + self, coresong: 'CoreSong', playlist: 'Playlist') -> Gtk.ListBoxRow: can_dnd = not playlist.props.is_smart song_widget = SongWidget(coresong, can_dnd, True) song_widget.props.show_song_number = False diff --unified --recursive --text --new-file --color gnome-music-41.1.old/gnomemusic/widgets/songwidgetmenu.py gnome-music-41.1.new/gnomemusic/widgets/songwidgetmenu.py --- gnome-music-41.1.old/gnomemusic/widgets/songwidgetmenu.py 2022-04-25 17:18:06.000000000 +0800 +++ gnome-music-41.1.new/gnomemusic/widgets/songwidgetmenu.py 2023-01-03 17:38:52.138368951 +0800 @@ -22,7 +22,6 @@ # code, but you are not obligated to do so. If you do not wish to do so, # delete this exception statement from your version. -from __future__ import annotations from typing import Union import typing @@ -46,8 +45,8 @@ _remove_from_playlist_button = Gtk.Template.Child() def __init__( - self, application: Application, song_widget: SongWidget, - coreobject: Union[CoreAlbum, CoreSong, Playlist]) -> None: + self, application: 'Application', song_widget: 'SongWidget', + coreobject: Union['CoreAlbum', 'CoreSong', Playlist]) -> None: """Menu to interact with the song of a SongWidget. :param Application application: The application object
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor