Code review comment for lp:~rharding/juju-gui/clear-tab-1199790

Revision history for this message
Richard Harding (rharding) wrote :

Reviewers: mp+174250_code.launchpad.net,

Message:
Please take a look.

Description:
TRIVIAL: selecting a charm resets hash.

- When clicking on a charm to view, it will reset the hash as well as
part of
the navigate change data.
- This is not directly tested because it would require setting
window.location.hash which could cause issues with later tests. The
navigate
change methods are all tested directly.

https://code.launchpad.net/~rharding/juju-gui/clear-tab-1199790/+merge/174250

(do not edit description out of merge proposal)

Please review this at https://codereview.appspot.com/10911046/

Affected files:
   A [revision details]
   M app/subapps/browser/views/charm.js
   M app/subapps/browser/views/charmresults.js

Index: [revision details]
=== added file '[revision details]'
--- [revision details] 2012-01-01 00:00:00 +0000
+++ [revision details] 2012-01-01 00:00:00 +0000
@@ -0,0 +1,2 @@
+Old revision: <email address hidden>
+New revision: <email address hidden>

Index: app/subapps/browser/views/charm.js
=== modified file 'app/subapps/browser/views/charm.js'
--- app/subapps/browser/views/charm.js 2013-07-03 17:35:21 +0000
+++ app/subapps/browser/views/charm.js 2013-07-11 16:51:45 +0000
@@ -271,7 +271,8 @@
        var charm = ev.currentTarget;
        var charmID = charm.getData('charmid');
        var change = {
- charmID: charmID
+ charmID: charmID,
+ hash: undefined
        };

        this.fire('viewNavigate', {change: change});

Index: app/subapps/browser/views/charmresults.js
=== modified file 'app/subapps/browser/views/charmresults.js'
--- app/subapps/browser/views/charmresults.js 2013-06-10 15:04:39 +0000
+++ app/subapps/browser/views/charmresults.js 2013-07-11 16:51:45 +0000
@@ -98,7 +98,8 @@
        }

        var change = {
- charmID: charmID
+ charmID: charmID,
+ hash: undefined
        };

        this.fire('viewNavigate', {change: change});

« Back to merge proposal