From: John L. <jr...@us...> - 2007-07-02 01:00:19
|
Update of /cvsroot/wxlua/wxLua/samples In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv4490/wxLua/samples Modified Files: media.wx.lua Log Message: Bump version to 2.8.4.1 Fix media.wx.lua for MSW Index: media.wx.lua =================================================================== RCS file: /cvsroot/wxlua/wxLua/samples/media.wx.lua,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** media.wx.lua 2 Jul 2007 00:11:43 -0000 1.1 --- media.wx.lua 2 Jul 2007 01:00:16 -0000 1.2 *************** *** 61,65 **** pause_ok = false stop_ok = true ! elseif state == wx.wxMEDIASTATE_STOPPED then play_ok = true pause_ok = false --- 61,65 ---- pause_ok = false stop_ok = true ! else --if state == wx.wxMEDIASTATE_STOPPED then play_ok = true pause_ok = false *************** *** 99,106 **** -- ----------------------------------------------------------------------- panel = wx.wxPanel(frame, wx.wxID_ANY) mediaCtrl = wx.wxMediaCtrl(panel, wx.wxID_ANY, "", ! wx.wxDefaultPosition, wx.wxDefaultSize) playButton = wx.wxButton(panel, ID_PLAY, "Play") --- 99,130 ---- -- ----------------------------------------------------------------------- + -- create a simple file menu + local fileMenu = wx.wxMenu() + fileMenu:Append(ID_LOADFILE, "Load media...\tCtrl+O", "Load a file to play...") + fileMenu:AppendSeparator() + fileMenu:Append(wx.wxID_EXIT, "E&xit\tCtrl+Q", "Quit the program") + + -- create a simple help menu + local helpMenu = wx.wxMenu() + helpMenu:Append(wx.wxID_ABOUT, "&About", "About the wxLua Media Application") + + -- create a menu bar and append the file and help menus + local menuBar = wx.wxMenuBar() + menuBar:Append(fileMenu, "&File") + menuBar:Append(helpMenu, "&Help") + + -- attach the menu bar into the frame + frame:SetMenuBar(menuBar) + + -- create a simple status bar + frame:CreateStatusBar(1) + frame:SetStatusText("Welcome to wxLua.") + + -- ----------------------------------------------------------------------- + panel = wx.wxPanel(frame, wx.wxID_ANY) mediaCtrl = wx.wxMediaCtrl(panel, wx.wxID_ANY, "", ! wx.wxDefaultPosition, wx.wxSize(200, 200)) playButton = wx.wxButton(panel, ID_PLAY, "Play") *************** *** 227,252 **** -- ----------------------------------------------------------------------- - -- create a simple file menu - local fileMenu = wx.wxMenu() - fileMenu:Append(ID_LOADFILE, "Load media...\tCtrl+O", "Load a file to play...") - fileMenu:AppendSeparator() - fileMenu:Append(wx.wxID_EXIT, "E&xit\tCtrl+Q", "Quit the program") - - -- create a simple help menu - local helpMenu = wx.wxMenu() - helpMenu:Append(wx.wxID_ABOUT, "&About", "About the wxLua Media Application") - - -- create a menu bar and append the file and help menus - local menuBar = wx.wxMenuBar() - menuBar:Append(fileMenu, "&File") - menuBar:Append(helpMenu, "&Help") - - -- attach the menu bar into the frame - frame:SetMenuBar(menuBar) - - -- create a simple status bar - frame:CreateStatusBar(1) - frame:SetStatusText("Welcome to wxLua.") - frame:Connect(ID_LOADFILE, wx.wxEVT_COMMAND_MENU_SELECTED, function (event) --- 251,254 ---- |