This commit is contained in:
Scott Erickson 2014-02-24 11:13:21 -08:00
commit 8138a5b678
4 changed files with 15 additions and 19 deletions
app
styles/play/level/tome
templates/play/level
views

View file

@ -77,7 +77,7 @@
.executed
background-color: rgba(245, 255, 6, 0.18)
.problem-marker-info
background-color: rgba(96, 63, 84, 0.25)
background-color: rgba(196, 163, 184, 0.25)
.problem-marker-warning
background-color: rgba(100, 65, 20, 0.25)
.problem-marker-error

View file

@ -1,6 +1,7 @@
.thang-avatar-wrapper(class="team-" + (thang.team || "neutral"))
//canvas(width=100, height=100, title=thang.id + " - " + thang.team)
img.img-responsive(src=avatarURL, title=thang.id + " - " + thang.team)
- var title = thang.id + " - " + thang.team + (thang.type ? ' - type: "' + thang.type + '"' : '')
img.img-responsive(src=avatarURL, title=title)
.badge.problems
.badge.shared-thangs
if includeName

View file

@ -48,15 +48,10 @@ module.exports = class ThangsTabView extends View
'click #extant-thangs-filter button': 'onFilterExtantThangs'
shortcuts:
'esc': -> @selectAddThang()
onFilterExtantThangs: (e) ->
button = $(e.target).closest('button')
button.button('toggle')
val = button.val()
@thangsTreema.$el.removeClass(@lastHideClass) if @lastHideClass
@thangsTreema.$el.addClass(@lastHideClass = "hide-except-#{val}") if val
'esc': 'selectAddThang'
'delete, del, backspace': 'deleteSelectedExtantThang'
'left': -> @moveAddThangSelection -1
'right': -> @moveAddThangSelection 1
constructor: (options) ->
super options
@ -102,12 +97,12 @@ module.exports = class ThangsTabView extends View
$('#thangs-list').bind 'mousewheel', @preventBodyScrollingInThangList
@$el.find('#extant-thangs-filter button:first').button('toggle')
# TODO: move these into the shortcuts list
key 'left', _.bind @moveAddThangSelection, @, -1
key 'right', _.bind @moveAddThangSelection, @, 1
key 'delete, del, backspace', @deleteSelectedExtantThang
key 'f', => Backbone.Mediator.publish('level-set-debug', debug: not @surface.debug)
key 'g', => Backbone.Mediator.publish('level-set-grid', grid: not @surface.gridShowing())
onFilterExtantThangs: (e) ->
button = $(e.target).closest('button')
button.button('toggle')
val = button.val()
@thangsTreema.$el.removeClass(@lastHideClass) if @lastHideClass
@thangsTreema.$el.addClass(@lastHideClass = "hide-except-#{val}") if val
preventBodyScrollingInThangList: (e) ->
@scrollTop += (if e.deltaY < 0 then 1 else -1) * 30

View file

@ -36,8 +36,8 @@ module.exports = class PlaybackView extends View
shortcuts:
'⌘+p, p, ctrl+p': 'onTogglePlay'
'[': 'onScrubBack'
']': 'onScrubForward'
'⌘+[, ctrl+[': 'onScrubBack'
'⌘+], ctrl+]': 'onScrubForward'
constructor: ->
super(arguments...)