mirror of
https://github.com/brunoherbelin/vimix.git
synced 2025-12-14 19:59:59 +01:00
bugfix show Player when clic source
This commit is contained in:
@@ -305,11 +305,12 @@ void UserInterface::handleKeyboard()
|
|||||||
}
|
}
|
||||||
else if (ImGui::IsKeyPressed( GLFW_KEY_P )) {
|
else if (ImGui::IsKeyPressed( GLFW_KEY_P )) {
|
||||||
// Media player
|
// Media player
|
||||||
Settings::application.widget.media_player = !Settings::application.widget.media_player;
|
sourcecontrol.setVisible(!Settings::application.widget.media_player);
|
||||||
if (Settings::application.widget.media_player_view != Settings::application.current_view) {
|
// Settings::application.widget.media_player = !Settings::application.widget.media_player;
|
||||||
Settings::application.widget.media_player_view = -1;
|
// if (Settings::application.widget.media_player_view != Settings::application.current_view) {
|
||||||
Settings::application.widget.media_player = true;
|
// Settings::application.widget.media_player_view = -1;
|
||||||
}
|
// Settings::application.widget.media_player = true;
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
else if (ImGui::IsKeyPressed( GLFW_KEY_A )) {
|
else if (ImGui::IsKeyPressed( GLFW_KEY_A )) {
|
||||||
if (shift_modifier_active)
|
if (shift_modifier_active)
|
||||||
@@ -1690,7 +1691,7 @@ void UserInterface::showSourceEditor(Source *s)
|
|||||||
if (s) {
|
if (s) {
|
||||||
Mixer::manager().setCurrentSource( s );
|
Mixer::manager().setCurrentSource( s );
|
||||||
if (s->playable()) {
|
if (s->playable()) {
|
||||||
Settings::application.widget.media_player = true;
|
sourcecontrol.setVisible(true);
|
||||||
sourcecontrol.resetActiveSelection();
|
sourcecontrol.resetActiveSelection();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -2488,6 +2489,15 @@ void SourceController::resetActiveSelection()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
void SourceController::setVisible(bool on)
|
||||||
|
{
|
||||||
|
if (on && Settings::application.widget.media_player_view != Settings::application.current_view)
|
||||||
|
Settings::application.widget.media_player_view = -1;
|
||||||
|
|
||||||
|
Settings::application.widget.media_player = on;
|
||||||
|
}
|
||||||
|
|
||||||
bool SourceController::Visible() const
|
bool SourceController::Visible() const
|
||||||
{
|
{
|
||||||
return ( Settings::application.widget.media_player
|
return ( Settings::application.widget.media_player
|
||||||
|
|||||||
@@ -255,6 +255,7 @@ public:
|
|||||||
|
|
||||||
void resetActiveSelection();
|
void resetActiveSelection();
|
||||||
void Render();
|
void Render();
|
||||||
|
void setVisible(bool on);
|
||||||
bool Visible() const;
|
bool Visible() const;
|
||||||
inline bool Foccused() const { return focused_; }
|
inline bool Foccused() const { return focused_; }
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user