sbWindowMoveService.h
Go to the documentation of this file.
1 /*
2  *=BEGIN SONGBIRD GPL
3  *
4  * This file is part of the Songbird web player.
5  *
6  * Copyright(c) 2005-2009 POTI, Inc.
7  * http://www.songbirdnest.com
8  *
9  * This file may be licensed under the terms of of the
10  * GNU General Public License Version 2 (the ``GPL'').
11  *
12  * Software distributed under the License is distributed
13  * on an ``AS IS'' basis, WITHOUT WARRANTY OF ANY KIND, either
14  * express or implied. See the GPL for the specific language
15  * governing rights and limitations.
16  *
17  * You should have received a copy of the GPL along with this
18  * program. If not, go to http://www.gnu.org/licenses/gpl.html
19  * or write to the Free Software Foundation, Inc.,
20  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21  *
22  *=END SONGBIRD GPL
23  */
24 
30 #ifndef __SB_WINDOWMOVE_SERVICE_H__
31 #define __SB_WINDOWMOVE_SERVICE_H__
32 
33 #include "sbIWindowMoveService.h"
34 
35 #include <nsITimer.h>
36 #include <nsHashKeys.h>
37 #include <nsInterfaceHashtable.h>
38 
39 #include <map>
40 
41 #include <windows.h>
42 
44  public nsITimerCallback
45 {
46 public:
48 
49 protected:
50  virtual ~sbWindowMoveService();
51 
52 public:
54  NS_DECL_SBIWINDOWMOVESERVICE
55  NS_DECL_NSITIMERCALLBACK
56 
57  typedef std::map<HWND, nsCOMPtr<sbIWindowMoveListener> > listeners_t;
58  typedef std::map<HWND, HHOOK> hooks_t;
59  typedef std::map<HWND, bool> resizing_t;
60 
61  typedef std::map<HWND, nsCOMPtr<nsITimer> > timers_t;
62  typedef std::map<nsITimer *, HWND> timertohwnd_t;
63 
64  nsresult Init();
65 
66  static LRESULT CALLBACK CallWndProc(int aCode, WPARAM wParam, LPARAM lParam);
67  PRBool IsHooked(HWND aWnd);
68 
69 protected:
73 
76 };
77 
78 #endif /*__SB_WINDOWMOVE_SERVICE_H__*/
NS_DECL_ISUPPORTS NS_DECL_SBIWINDOWMOVESERVICE NS_DECL_NSITIMERCALLBACK typedef std::map< HWND, nsCOMPtr< sbIWindowMoveListener > > listeners_t
PRBool IsHooked(HWND aWnd)
std::map< HWND, bool > resizing_t
timertohwnd_t mTimersToWnd
std::map< nsITimer *, HWND > timertohwnd_t
std::map< HWND, HHOOK > hooks_t
std::map< HWND, nsCOMPtr< nsITimer > > timers_t
nsITimerCallback
static LRESULT CALLBACK CallWndProc(int aCode, WPARAM wParam, LPARAM lParam)