Move action_runner.py out of actions folder prior to moving actions to internal.
[chromium-blink-merge.git] / ui / chromeos / network / network_list_delegate.h
blobabdf3ad395fd95039cbfbfb13704588a876d3fd0
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef UI_CHROMEOS_NETWORK_NETWORK_LIST_DELEGATE_H_
6 #define UI_CHROMEOS_NETWORK_NETWORK_LIST_DELEGATE_H_
8 #include "ui/chromeos/ui_chromeos_export.h"
10 namespace chromeos {
11 class NetworkState;
12 class NetworkTypePattern;
15 namespace views {
16 class Label;
17 class View;
20 namespace ui {
22 struct NetworkInfo;
24 class UI_CHROMEOS_EXPORT NetworkListDelegate {
25 public:
26 virtual ~NetworkListDelegate() {}
28 // Creates and returns a View with the information in |info|.
29 virtual views::View* CreateViewForNetwork(const NetworkInfo& info) = 0;
31 // Returns true if |view| is currently under the cursor. Note that |view| is
32 // guaranteed to be a View returned from |CreateViewForNetwork()|.
33 virtual bool IsViewHovered(views::View* view) = 0;
35 // Returns the type of network this list should use.
36 virtual chromeos::NetworkTypePattern GetNetworkTypePattern() const = 0;
38 // Updates |view| with the information in |info|. Note that |view| is
39 // guaranteed to be a View returned from |CreateViewForNetwork()|.
40 virtual void UpdateViewForNetwork(views::View* view,
41 const NetworkInfo& info) = 0;
43 // Creates a Label to be displayed in the list to present some information
44 // (e.g. unavailability of network etc.).
45 virtual views::Label* CreateInfoLabel() = 0;
47 // Called when the user clicks on an entry representing a network in the list.
48 virtual void OnViewClicked(views::View* sender) = 0;
50 virtual void RelayoutScrollList() = 0;
53 } // namespace ui
55 #endif // UI_CHROMEOS_NETWORK_NETWORK_LIST_DELEGATE_H_