Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(227)

Side by Side Diff: chrome/browser/resources/chromeos/login/header_bar.js

Issue 8681029: [cros] Make disconnected icons used by network drop-down and network button consistent. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merged Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * @fileoverview Login UI header bar implementation. 6 * @fileoverview Login UI header bar implementation.
7 */ 7 */
8 8
9 cr.define('login', function() { 9 cr.define('login', function() {
10 // Network state constants. 10 // Network state constants.
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 chrome.send('shutdownSystem'); 77 chrome.send('shutdownSystem');
78 } 78 }
79 }; 79 };
80 80
81 /** 81 /**
82 * Continues add user button click handling after network state has 82 * Continues add user button click handling after network state has
83 * been recieved. 83 * been recieved.
84 * @param {Integer} state Current state of the network (see NET_STATE). 84 * @param {Integer} state Current state of the network (see NET_STATE).
85 * @param {string} network Name of the network. 85 * @param {string} network Name of the network.
86 * @param {string} reason Reason the callback was called. 86 * @param {string} reason Reason the callback was called.
87 * @param {int} last Last active network type.
87 */ 88 */
88 HeaderBar.handleAddUser = function(state, network, reason) { 89 HeaderBar.handleAddUser = function(state, network, reason, last) {
89 if (state != NET_STATE.OFFLINE) { 90 if (state != NET_STATE.OFFLINE) {
90 Oobe.showSigninUI(); 91 Oobe.showSigninUI();
91 } else { 92 } else {
92 $('bubble').showTextForElement($('add-user-button'), 93 $('bubble').showTextForElement($('add-user-button'),
93 localStrings.getString('addUserErrorMessage')); 94 localStrings.getString('addUserErrorMessage'));
94 chrome.send('loginAddNetworkStateObserver', 95 chrome.send('loginAddNetworkStateObserver',
95 ['login.HeaderBar.bubbleWatchdog']); 96 ['login.HeaderBar.bubbleWatchdog']);
96 } 97 }
97 }; 98 };
98 99
99 /** 100 /**
100 * Observes network state, and close the bubble when network becomes online. 101 * Observes network state, and close the bubble when network becomes online.
101 * @param {Integer} state Current state of the network (see NET_STATE). 102 * @param {Integer} state Current state of the network (see NET_STATE).
102 * @param {string} network Name of the network. 103 * @param {string} network Name of the network.
103 * @param {string} reason Reason the callback was called. 104 * @param {string} reason Reason the callback was called.
105 * @param {int} last Last active network type.
104 */ 106 */
105 HeaderBar.bubbleWatchdog = function(state, network, reason) { 107 HeaderBar.bubbleWatchdog = function(state, network, reason, last) {
106 if (state != NET_STATE.OFFLINE) { 108 if (state != NET_STATE.OFFLINE) {
107 $('bubble').hideForElement($('add-user-button')); 109 $('bubble').hideForElement($('add-user-button'));
108 chrome.send('loginRemoveNetworkStateObserver', 110 chrome.send('loginRemoveNetworkStateObserver',
109 ['login.HeaderBar.bubbleWatchdog']); 111 ['login.HeaderBar.bubbleWatchdog']);
110 } 112 }
111 }; 113 };
112 114
113 return { 115 return {
114 HeaderBar: HeaderBar 116 HeaderBar: HeaderBar
115 }; 117 };
116 }); 118 });
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/status/network_menu_icon.h ('k') | chrome/browser/resources/chromeos/login/network_dropdown.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698