From 6afb1d93744a73f225ca7793e58e0ca807062e66 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Emmanuel=20Beno=C3=AEt?= <tseeker@nocternity.net>
Date: Fri, 24 Nov 2017 12:05:40 +0100
Subject: [PATCH] UI - Use actions in sequencer toolbar

---
 ui-actions.cc   | 2 +-
 ui-sequencer.cc | 7 ++++---
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/ui-actions.cc b/ui-actions.cc
index 24dbec5..675e498 100644
--- a/ui-actions.cc
+++ b/ui-actions.cc
@@ -77,7 +77,7 @@ void T_UIAction::tbButton( ) const noexcept
 		if ( shortcut ) {
 			char kbs[ 20 ];
 			shortcut->toString( kbs , 20 );
-			sb << ' ' << kbs;
+			sb << " (" << kbs << ')';
 		}
 		sb << '\0';
 
diff --git a/ui-sequencer.cc b/ui-sequencer.cc
index 9a173c7..fa71371 100644
--- a/ui-sequencer.cc
+++ b/ui-sequencer.cc
@@ -293,9 +293,10 @@ void T_SyncViewImpl_::displayToolbar( ) noexcept
 	using namespace ImGui;
 	auto& sync( Common::Sync( ) );
 
-	if ( ToolbarButton( sync.playing( ) ? ICON_FA_STOP : ICON_FA_PLAY , BtSize ,
-			sync.playing( ) ? "Stop" : "Play" ) ) {
-		sync.playing( ) = !sync.playing( ) && !sync.finished( );
+	if ( sync.playing( ) ) {
+		UI::Main( ).actionButton( "Stop" );
+	} else {
+		UI::Main( ).actionButton( "Play" );
 	}
 
 	SameLine( );