Thu, 22 Jan 2015 13:21:57 +0100
Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6
1 /* vim: se cin sw=2 ts=2 et : */
2 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
3 *
4 * This Source Code Form is subject to the terms of the Mozilla Public
5 * License, v. 2.0. If a copy of the MPL was not distributed with this
6 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
8 #ifndef __mozilla_widget_TaskbarPreviewButton_h__
9 #define __mozilla_widget_TaskbarPreviewButton_h__
11 #include <windows.h>
12 #include <shobjidl.h>
13 #undef LogSeverity // SetupAPI.h #defines this as DWORD
15 #include <nsITaskbarPreviewButton.h>
16 #include <nsAutoPtr.h>
17 #include <nsString.h>
18 #include <nsWeakReference.h>
20 namespace mozilla {
21 namespace widget {
23 class TaskbarWindowPreview;
24 class TaskbarPreviewButton : public nsITaskbarPreviewButton, public nsSupportsWeakReference
25 {
26 public:
27 TaskbarPreviewButton(TaskbarWindowPreview* preview, uint32_t index);
28 virtual ~TaskbarPreviewButton();
30 NS_DECL_ISUPPORTS
31 NS_DECL_NSITASKBARPREVIEWBUTTON
33 private:
34 THUMBBUTTON& Button();
35 nsresult Update();
37 nsRefPtr<TaskbarWindowPreview> mPreview;
38 uint32_t mIndex;
39 nsString mTooltip;
40 nsCOMPtr<imgIContainer> mImage;
41 };
43 } // namespace widget
44 } // namespace mozilla
46 #endif /* __mozilla_widget_TaskbarPreviewButton_h__ */