comparison rhodecode/controllers/changeset.py @ 1859:929fc8d926d5 beta

changeset: replace diff/whitespace/context popup menu with icons
author Aras Pranckevicius <aras@unity3d.com>
date Sat, 07 Jan 2012 19:07:00 +0200
parents 89efedac4e6c
children 2112bcbcb346
comparison
equal deleted inserted replaced
1858:609ec28bd2d1 1859:929fc8d926d5
91 # if we have passed in ln_ctx pass it along to our params 91 # if we have passed in ln_ctx pass it along to our params
92 if ln_ctx: 92 if ln_ctx:
93 params[ctx_key] += [ctx_val] 93 params[ctx_key] += [ctx_val]
94 94
95 params['anchor'] = fileid 95 params['anchor'] = fileid
96 return h.link_to(lbl, h.url.current(**params)) 96 img = h.image('/images/icons/text_strikethrough.png', lbl, class_='icon')
97 return h.link_to(img, h.url.current(**params), title=lbl)
97 98
98 99
99 def get_line_ctx(fid, GET): 100 def get_line_ctx(fid, GET):
100 ln_ctx_global = request.GET.get('context') 101 ln_ctx_global = request.GET.get('context')
101 ln_ctx = filter(lambda k: k.startswith('C'), GET.getall(fid)) 102 ln_ctx = filter(lambda k: k.startswith('C'), GET.getall(fid))
141 params[ig_ws_key] += [ig_ws_val] 142 params[ig_ws_key] += [ig_ws_val]
142 143
143 lbl = _('%s line context') % ln_ctx 144 lbl = _('%s line context') % ln_ctx
144 145
145 params['anchor'] = fileid 146 params['anchor'] = fileid
146 return h.link_to(lbl, h.url.current(**params)) 147 img = h.image('/images/icons/table_add.png', lbl, class_='icon')
148 return h.link_to(img, h.url.current(**params), title=lbl)
147 149
148 150
149 class ChangesetController(BaseRepoController): 151 class ChangesetController(BaseRepoController):
150 152
151 @LoginRequired() 153 @LoginRequired()