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

Unified Diff: chrome/browser/chromeos/status/memory_menu_button.h

Issue 10056001: chromeos: Remove old status-area related code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 8 months 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/status/memory_menu_button.h
diff --git a/chrome/browser/chromeos/status/memory_menu_button.h b/chrome/browser/chromeos/status/memory_menu_button.h
deleted file mode 100644
index 9747c474e4106c3fa97a962d8908a16e34502bbf..0000000000000000000000000000000000000000
--- a/chrome/browser/chromeos/status/memory_menu_button.h
+++ /dev/null
@@ -1,80 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_BROWSER_CHROMEOS_STATUS_MEMORY_MENU_BUTTON_H_
-#define CHROME_BROWSER_CHROMEOS_STATUS_MEMORY_MENU_BUTTON_H_
-#pragma once
-
-#include "base/memory/scoped_ptr.h"
-#include "base/timer.h"
-#include "chrome/browser/chromeos/status/status_area_button.h"
-#include "content/public/browser/notification_observer.h"
-#include "content/public/browser/notification_registrar.h"
-#include "ui/views/controls/button/menu_button_listener.h"
-#include "ui/views/controls/menu/menu_delegate.h"
-
-namespace base {
-struct SystemMemoryInfoKB;
-}
-
-namespace views {
-class MenuItemView;
-class MenuRunner;
-}
-
-// Memory debugging display that lives in the status area.
-class MemoryMenuButton : public StatusAreaButton,
- public views::MenuDelegate,
- public views::MenuButtonListener,
- public content::NotificationObserver {
- public:
- explicit MemoryMenuButton(StatusAreaButton::Delegate* delegate);
- virtual ~MemoryMenuButton();
-
- // views::MenuDelegate implementation
- virtual string16 GetLabel(int id) const OVERRIDE;
- virtual bool IsCommandEnabled(int id) const OVERRIDE;
- virtual void ExecuteCommand(int id) OVERRIDE;
-
- // views::MenuButtonListener implementation.
- virtual void OnMenuButtonClicked(views::View* source,
- const gfx::Point& point) OVERRIDE;
-
- // content::NotificationObserver overrides.
- virtual void Observe(int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) OVERRIDE;
-
- // Updates the text on the menu button.
- void UpdateText();
-
- protected:
- virtual int horizontal_padding() OVERRIDE;
-
- private:
- // Execute command id for each renderer. Used for heap profiling.
- void SendCommandToRenderers(int id);
-
- // Creates and returns the menu. The caller owns the returned value.
- views::MenuItemView* CreateMenu();
-
- // Updates text and schedules the timer to fire at the next minute interval.
- void UpdateTextAndSetNextTimer();
-
- base::OneShotTimer<MemoryMenuButton> timer_;
-
- // Raw data from /proc/meminfo
- scoped_ptr<base::SystemMemoryInfoKB> meminfo_;
-
- content::NotificationRegistrar registrar_;
-
- // Number of renderer kills we have observed.
- int renderer_kills_;
-
- scoped_ptr<views::MenuRunner> menu_runner_;
-
- DISALLOW_COPY_AND_ASSIGN(MemoryMenuButton);
-};
-
-#endif // CHROME_BROWSER_CHROMEOS_STATUS_MEMORY_MENU_BUTTON_H_
« no previous file with comments | « chrome/browser/chromeos/status/input_method_menu_unittest.cc ('k') | chrome/browser/chromeos/status/memory_menu_button.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698