/spacey

To get this branch, use:
bzr branch http://9ix.org/bzr/spacey

« back to all changes in this revision

Viewing changes to main.lua

  • Committer: Josh C
  • Date: 2013-06-08 00:02:37 UTC
  • Revision ID: josh@9ix.org-20130608000237-v50hyqvrinp5g4rs
try to make setting screen resolution more reliable

Show diffs side-by-side

added added

removed removed

Lines of Context:
260
260
 
261
261
              self.view = GameView:new()
262
262
 
263
 
              -- should fail silently if it can't go to fullscreen...
 
263
              -- try going fullscreen.  should fail silently if it
 
264
              -- can't go to fullscreen.
264
265
              love.graphics.toggleFullscreen()
265
266
 
266
267
              if DEBUG then
282
283
                 if the.keys:justPressed('q') then
283
284
                    self.quit()
284
285
                 elseif the.keys:justPressed('return') then
285
 
                    if the.keys:pressed('alt') then
286
 
                       love.graphics.toggleFullscreen()
287
 
                    else
288
 
                       self.view = GameView:new()
289
 
                    end
 
286
                    self.view = GameView:new()
290
287
                 elseif the.keys:justPressed('f1') then
291
288
                    local ss = love.graphics.newScreenshot()
292
289
                    ss:encode('screenshot-' ..love.timer.getTime()..'.png')
293
 
                 elseif the.keys:justPressed('f11') then
294
 
                    love.graphics.toggleFullscreen()
295
290
                 end
296
291
              end,
297
292
   update = function (self, dt)