1 // Copyright 2013 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 CHROME_BROWSER_UI_COCOA_LOCATION_BAR_MIC_SEARCH_DECORATION_H_
6 #define CHROME_BROWSER_UI_COCOA_LOCATION_BAR_MIC_SEARCH_DECORATION_H_
8 #import <Cocoa/Cocoa.h>
10 #include "chrome/browser/ui/cocoa/location_bar/image_decoration.h"
14 // Draws a microphone icon on the right side of the omnibox. This is used for
16 class MicSearchDecoration : public ImageDecoration {
18 explicit MicSearchDecoration(CommandUpdater* command_updater);
19 ~MicSearchDecoration() override;
21 // Implement |LocationBarDecoration|.
22 bool AcceptsMousePress() override;
23 bool OnMousePressed(NSRect frame, NSPoint location) override;
24 NSString* GetToolTip() override;
27 CommandUpdater* command_updater_; // Weak, owned by Browser.
29 DISALLOW_COPY_AND_ASSIGN(MicSearchDecoration);
32 #endif // CHROME_BROWSER_UI_COCOA_LOCATION_BAR_MIC_SEARCH_DECORATION_H_