mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2025-05-04 09:53:55 -04:00
Merge branch 'master' of https://github.com/codecombat/codecombat
This commit is contained in:
commit
8138a5b678
4 changed files with 15 additions and 19 deletions
app
styles/play/level/tome
templates/play/level
views
|
@ -77,7 +77,7 @@
|
||||||
.executed
|
.executed
|
||||||
background-color: rgba(245, 255, 6, 0.18)
|
background-color: rgba(245, 255, 6, 0.18)
|
||||||
.problem-marker-info
|
.problem-marker-info
|
||||||
background-color: rgba(96, 63, 84, 0.25)
|
background-color: rgba(196, 163, 184, 0.25)
|
||||||
.problem-marker-warning
|
.problem-marker-warning
|
||||||
background-color: rgba(100, 65, 20, 0.25)
|
background-color: rgba(100, 65, 20, 0.25)
|
||||||
.problem-marker-error
|
.problem-marker-error
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
.thang-avatar-wrapper(class="team-" + (thang.team || "neutral"))
|
.thang-avatar-wrapper(class="team-" + (thang.team || "neutral"))
|
||||||
//canvas(width=100, height=100, title=thang.id + " - " + thang.team)
|
//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.problems
|
||||||
.badge.shared-thangs
|
.badge.shared-thangs
|
||||||
if includeName
|
if includeName
|
||||||
|
|
|
@ -48,15 +48,10 @@ module.exports = class ThangsTabView extends View
|
||||||
'click #extant-thangs-filter button': 'onFilterExtantThangs'
|
'click #extant-thangs-filter button': 'onFilterExtantThangs'
|
||||||
|
|
||||||
shortcuts:
|
shortcuts:
|
||||||
'esc': -> @selectAddThang()
|
'esc': 'selectAddThang'
|
||||||
|
'delete, del, backspace': 'deleteSelectedExtantThang'
|
||||||
onFilterExtantThangs: (e) ->
|
'left': -> @moveAddThangSelection -1
|
||||||
button = $(e.target).closest('button')
|
'right': -> @moveAddThangSelection 1
|
||||||
button.button('toggle')
|
|
||||||
val = button.val()
|
|
||||||
@thangsTreema.$el.removeClass(@lastHideClass) if @lastHideClass
|
|
||||||
@thangsTreema.$el.addClass(@lastHideClass = "hide-except-#{val}") if val
|
|
||||||
|
|
||||||
|
|
||||||
constructor: (options) ->
|
constructor: (options) ->
|
||||||
super options
|
super options
|
||||||
|
@ -102,12 +97,12 @@ module.exports = class ThangsTabView extends View
|
||||||
$('#thangs-list').bind 'mousewheel', @preventBodyScrollingInThangList
|
$('#thangs-list').bind 'mousewheel', @preventBodyScrollingInThangList
|
||||||
@$el.find('#extant-thangs-filter button:first').button('toggle')
|
@$el.find('#extant-thangs-filter button:first').button('toggle')
|
||||||
|
|
||||||
# TODO: move these into the shortcuts list
|
onFilterExtantThangs: (e) ->
|
||||||
key 'left', _.bind @moveAddThangSelection, @, -1
|
button = $(e.target).closest('button')
|
||||||
key 'right', _.bind @moveAddThangSelection, @, 1
|
button.button('toggle')
|
||||||
key 'delete, del, backspace', @deleteSelectedExtantThang
|
val = button.val()
|
||||||
key 'f', => Backbone.Mediator.publish('level-set-debug', debug: not @surface.debug)
|
@thangsTreema.$el.removeClass(@lastHideClass) if @lastHideClass
|
||||||
key 'g', => Backbone.Mediator.publish('level-set-grid', grid: not @surface.gridShowing())
|
@thangsTreema.$el.addClass(@lastHideClass = "hide-except-#{val}") if val
|
||||||
|
|
||||||
preventBodyScrollingInThangList: (e) ->
|
preventBodyScrollingInThangList: (e) ->
|
||||||
@scrollTop += (if e.deltaY < 0 then 1 else -1) * 30
|
@scrollTop += (if e.deltaY < 0 then 1 else -1) * 30
|
||||||
|
|
|
@ -36,8 +36,8 @@ module.exports = class PlaybackView extends View
|
||||||
|
|
||||||
shortcuts:
|
shortcuts:
|
||||||
'⌘+p, p, ctrl+p': 'onTogglePlay'
|
'⌘+p, p, ctrl+p': 'onTogglePlay'
|
||||||
'[': 'onScrubBack'
|
'⌘+[, ctrl+[': 'onScrubBack'
|
||||||
']': 'onScrubForward'
|
'⌘+], ctrl+]': 'onScrubForward'
|
||||||
|
|
||||||
constructor: ->
|
constructor: ->
|
||||||
super(arguments...)
|
super(arguments...)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue