rtoss - Blame information for rev 359

Subversion Repositories:
Rev:
Rev Author Line No. Line
181 roytam 1 /* ----------------------------------------------------------------------------
2  
3     gen_tbar
4     ========
5     Winamp plugin to display customizable data on window captions
6  
7     Copyright (c) 1999-2000 Jos van den Oever (http://www.vandenoever.info/)
8     Copyright (c) 2005 Martin Zuther (http://www.mzuther.de/)
9  
10     This program is free software; you can redistribute it and/or modify
11     it under the terms of the GNU General Public License as published by
12     the Free Software Foundation; either version 2 of the License, or
13     (at your option) any later version.
14  
15     This program is distributed in the hope that it will be useful,
16     but WITHOUT ANY WARRANTY; without even the implied warranty of
17     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18     GNU General Public License for more details.
19  
20     You should have received a copy of the GNU General Public License
21     along with this program; if not, write to the Free Software
22     Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23  
24 -------------------------------------------------------------------------------
25  
26     Notify CD Player
27     ================
28     Copyright (c) 1996-1997 Mats Ljungqvist (mlt@cyberdude.com)
29  
30     StdString
31     =========
32     Copyright (c) 2002 Joseph M. O'Leary.  This code is 100% free.  Use it
33     anywhere you want. Rewrite it, restructure it, whatever.  If you can write
34     software that makes money off of it, good for you.  I kinda like capitalism.
35     Please don't blame me if it causes your $30 billion dollar satellite explode
36     in orbit. If you redistribute it in any form, I'd appreciate it if you would
37     leave this notice here.
38  
39 ---------------------------------------------------------------------------- */
40  
41 // class TitleInfo
42  
43 #ifndef TITLEINFO_H
44 #define TITLEINFO_H
45  
46 #include "stdafx.h"
47 #include "resource.h"
48  
49 #include <commctrl.h>
50 #include <commdlg.h>
51 #include <stdio.h>
52 #include <stdlib.h>
53 #include "StdString.h"
54  
55 class TitleInfo
56 {
57 public:
58         TitleInfo();
59         ~TitleInfo();
60         void drawOnCaption();
61         void setText(CStdString newTitleText);
62         void setSearchCaption(CStdString newSearchCaption);
63         bool isStringInCaption(CStdString WindowText);
64         void setShowPlayStatus(bool newstatus)                                                  { bShowPlayStatus = newstatus; }
65         void setFont(LOGFONT lfont)                                                                             { sCaptionFont = lfont; }
66         void setFontColor(const DWORD newcolor)                                                 { nCaptionFontColor = newcolor; }
67         void setFontShift(int newHorizontalShift, int newVerticalShift) { nHorizontalShift = newHorizontalShift; nVerticalShift   = newVerticalShift; }
68  
69 private:
70         DWORD   nCaptionFontColor;
71         LOGFONT sCaptionFont;
72         HWND    hLastForegroundWindow;
73  
74         int nHorizontalShift;
75         int nVerticalShift;
76  
77         CStdString* pSearchCaption;
78  
79         CStdString strTitleText;
80  
359 roytam 81         RECT rectOldDimension;
82         bool bODInited;
83  
181 roytam 84         bool bShowPlayStatus;
85  
86         void drawCaption(HWND hForegroundWnd, unsigned int nStyle);
87         void updateCaption(HWND hWnd);
88 };
89  
90 #endif