ShellViewsDelegateAura() : use_transparent_windows_(false) {
}
- virtual ~ShellViewsDelegateAura() {
- }
+ ~ShellViewsDelegateAura() override {}
void SetUseTransparentWindows(bool transparent) {
use_transparent_windows_ = transparent;
}
// ui::SimpleMenuModel::Delegate:
- virtual bool IsCommandIdChecked(int command_id) const OVERRIDE {
+ bool IsCommandIdChecked(int command_id) const override { return false; }
+ bool IsCommandIdEnabled(int command_id) const override { return true; }
+ bool GetAcceleratorForCommandId(int command_id,
+ ui::Accelerator* accelerator) override {
return false;
}
- virtual bool IsCommandIdEnabled(int command_id) const OVERRIDE {
- return true;
- }
- virtual bool GetAcceleratorForCommandId(
- int command_id,
- ui::Accelerator* accelerator) OVERRIDE { return false; }
- virtual void ExecuteCommand(int command_id, int event_flags) OVERRIDE {
+ void ExecuteCommand(int command_id, int event_flags) override {
switch (command_id) {
case COMMAND_OPEN_DEVTOOLS:
shell_->ShowDevToolsForElementAt(params_.x, params_.y);
toolbar_view_(new View),
contents_view_(new View) {
}
- virtual ~ShellWindowDelegateView() {}
+ ~ShellWindowDelegateView() override {}
// Update the state of UI controls
void SetAddressBarURL(const GURL& url) {
}
}
// Overridden from TextfieldController
- virtual void ContentsChanged(views::Textfield* sender,
- const base::string16& new_contents) OVERRIDE {
- }
- virtual bool HandleKeyEvent(views::Textfield* sender,
- const ui::KeyEvent& key_event) OVERRIDE {
+ void ContentsChanged(views::Textfield* sender,
+ const base::string16& new_contents) override {}
+ bool HandleKeyEvent(views::Textfield* sender,
+ const ui::KeyEvent& key_event) override {
if (sender == url_entry_ && key_event.key_code() == ui::VKEY_RETURN) {
std::string text = base::UTF16ToUTF8(url_entry_->text());
GURL url(text);
}
// Overridden from ButtonListener
- virtual void ButtonPressed(views::Button* sender,
- const ui::Event& event) OVERRIDE {
+ void ButtonPressed(views::Button* sender, const ui::Event& event) override {
if (sender == back_button_)
shell_->GoBackOrForward(-1);
else if (sender == forward_button_)
}
// Overridden from WidgetDelegateView
- virtual bool CanResize() const OVERRIDE { return true; }
- virtual bool CanMaximize() const OVERRIDE { return true; }
- virtual bool CanMinimize() const OVERRIDE { return true; }
- virtual base::string16 GetWindowTitle() const OVERRIDE {
- return title_;
- }
- virtual void WindowClosing() OVERRIDE {
+ bool CanResize() const override { return true; }
+ bool CanMaximize() const override { return true; }
+ bool CanMinimize() const override { return true; }
+ base::string16 GetWindowTitle() const override { return title_; }
+ void WindowClosing() override {
if (shell_) {
delete shell_;
shell_ = NULL;
}
}
- virtual View* GetContentsView() OVERRIDE { return this; }
+ View* GetContentsView() override { return this; }
// Overridden from View
- virtual gfx::Size GetMinimumSize() const OVERRIDE {
+ gfx::Size GetMinimumSize() const override {
// We want to be able to make the window smaller than its initial
// (preferred) size.
return gfx::Size();
}
- virtual void ViewHierarchyChanged(
- const ViewHierarchyChangedDetails& details) OVERRIDE {
+ void ViewHierarchyChanged(
+ const ViewHierarchyChangedDetails& details) override {
if (details.is_add && details.child == this) {
InitShellWindow();
}
}
// Overridden from AcceleratorTarget:
- virtual bool AcceleratorPressed(const ui::Accelerator& accelerator) OVERRIDE {
+ bool AcceleratorPressed(const ui::Accelerator& accelerator) override {
switch (accelerator.key_code()) {
case ui::VKEY_F5:
shell_->Reload();