diff options
author | Will Thompson <will@willthompson.co.uk> | 2012-01-27 09:25:35 +0000 |
---|---|---|
committer | Will Thompson <will@willthompson.co.uk> | 2012-01-27 09:25:35 +0000 |
commit | 4578cafdf45cc6f7f10e50448f0b52f9aa3a95eb (patch) | |
tree | 5de5c715c6ebce95996cbeac3fb11a4efb5eb2bf /Bustle | |
parent | c53e558f8e4e7058567c081ce20023dab037f0c9 (diff) |
Replace instructions with buttons.
https://bugs.freedesktop.org/show_bug.cgi?id=44889
Diffstat (limited to 'Bustle')
-rw-r--r-- | Bustle/UI.hs | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/Bustle/UI.hs b/Bustle/UI.hs index 7139cb6..bd38e03 100644 --- a/Bustle/UI.hs +++ b/Bustle/UI.hs @@ -326,6 +326,7 @@ emptyWindow = do [newItem, openItem, saveItem, closeItem, aboutItem] <- mapM (getW castToImageMenuItem) ["new", "open", "save", "close", "about"] + [newButton, openButton] <- mapM (getW castToButton) ["newButton", "openButton"] exportItem <- getW castToMenuItem "export" openTwoItem <- getW castToMenuItem "openTwo" viewStatistics <- getW castToCheckMenuItem "statistics" @@ -346,10 +347,17 @@ emptyWindow = do withProgramIcon (windowSetIcon window) embedIO $ onDestroy window . makeCallback maybeQuit - -- File menu - embedIO $ onActivateLeaf newItem . makeCallback startRecording - embedIO $ onActivateLeaf openItem . makeCallback (openDialogue window) - io $ openTwoItem `onActivateLeaf` widgetShowAll openTwoDialog + -- File menu and related buttons + embedIO $ \r -> do + let new = makeCallback startRecording r + onActivateLeaf newItem new + onClicked newButton new + + let open = makeCallback (openDialogue window) r + onActivateLeaf openItem open + onClicked openButton open + + onActivateLeaf openTwoItem $ widgetShowAll openTwoDialog -- Help menu withProgramIcon $ \icon -> io $ |