forked from trav/lintunes
v0.65.0: DJ mode round three, and the small things
- The shelf is revealed in place: the decks don't stretch or squeeze as the window parts. - The DJ button is the top row's last box (where bpm was), so it stays put; bpm moved under it. - Tempo, vocals and the crossfader snap to their middle and show it. The vocals slider has icons, lined up with its ends and middle. - Sync sticks: a synced deck follows the other's tempo, glows and says Synced until its own tempo fader moves. The ½×/1×/2× switch re-syncs, and the BPM line says when it's counted half or double. - A back-to-the-start button per deck. - The air horn is a real recording (CC0): tap for the phrase, hold to stretch the first blast. - The zoomed waveforms ease out while a deck is paused or held. - DJ audio follows a change of output device instead of going silent. - A new playlist folder is named in place, scrolled into view. - Visualizer bars: choose how many, 1 to 1024 (one per pixel at most). - The volume slider is as tall as the scrubber.
This commit is contained in:
@@ -448,7 +448,7 @@ class MainWindow(QMainWindow):
|
||||
self._add_action(file_menu, "New Smart Playlist", "Ctrl+Alt+N",
|
||||
lambda: self._sidebar.tree.create_smart_playlist_interactive())
|
||||
self._add_action(file_menu, "New Playlist Folder", "Ctrl+Shift+N",
|
||||
lambda: self._manager.create_folder("untitled folder"))
|
||||
lambda: self._sidebar.tree.create_folder_interactive())
|
||||
file_menu.addSeparator()
|
||||
self._add_action(file_menu, "Add Files to Library…", "Ctrl+O",
|
||||
self._open_files_dialog)
|
||||
@@ -2398,6 +2398,7 @@ class MainWindow(QMainWindow):
|
||||
self._transport.set_dj_mode(True, self._dj_titles())
|
||||
track_table.deck_tag = self._deck_tag
|
||||
shelf.set_master(self._dj_master())
|
||||
shelf.set_layout_height(target) # laid out full size, revealed
|
||||
shelf.setFixedHeight(0)
|
||||
shelf.show()
|
||||
shelf.start()
|
||||
@@ -2407,6 +2408,7 @@ class MainWindow(QMainWindow):
|
||||
else:
|
||||
shelf = self._dj
|
||||
track_table.deck_tag = None
|
||||
shelf.set_layout_height(shelf.height()) # covered, not squeezed
|
||||
self._animate_shelf(shelf.height(), 0, done=self._dj_closed)
|
||||
self._refresh_tables()
|
||||
|
||||
@@ -2487,7 +2489,9 @@ class MainWindow(QMainWindow):
|
||||
if self._dj_resize_from is None:
|
||||
self._dj_resize_from = self._dj.height()
|
||||
low, high = self._dj_bounds()
|
||||
self._dj.setFixedHeight(max(low, min(high, self._dj_resize_from + dy)))
|
||||
height = max(low, min(high, self._dj_resize_from + dy))
|
||||
self._dj.set_layout_height(height)
|
||||
self._dj.setFixedHeight(height)
|
||||
|
||||
def _on_dj_resize_done(self):
|
||||
self._dj_resize_from = None
|
||||
@@ -2502,8 +2506,9 @@ class MainWindow(QMainWindow):
|
||||
config = load_config()
|
||||
config.pop("dj_shelf_height", None)
|
||||
save_config(config)
|
||||
self._animate_shelf(self._dj.height(),
|
||||
max(low, min(high, default_height(viewport, row))))
|
||||
target = max(low, min(high, default_height(viewport, row)))
|
||||
self._dj.set_layout_height(target)
|
||||
self._animate_shelf(self._dj.height(), target)
|
||||
|
||||
def _deck_tag(self, track_id: int):
|
||||
if self._dj is None:
|
||||
|
||||
Reference in New Issue
Block a user