~flosoft/s25rttr/trunk

« back to all changes in this revision

Viewing changes to src/Window.cpp

  • Committer: FloSoft
  • Date: 2014-04-25 15:35:50 UTC
  • Revision ID: flosoft@siedler25.org-20140425153550-9muu4vodhlqu58m0
committing subversion revision 9357 by FloSoft
astyle

modified:
s25client/trunk/
s25client/trunk/contrib/lua/lin32/include/
s25client/trunk/contrib/lua/lin64/include/
s25client/trunk/contrib/lua/mac/include/
s25client/trunk/contrib/lua/win32/include/
s25client/trunk/contrib/lua/win64/include/
s25client/trunk/driver/audio/SDL/src/
s25client/trunk/driver/src/
s25client/trunk/driver/video/GLFW/src/
s25client/trunk/driver/video/SDL/src/
s25client/trunk/driver/video/WinAPI/src/
s25client/trunk/src/
s25client/trunk/win32/
s25client/trunk/win32/prebuild-mutex/src/

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
// $Id: Window.cpp 8103 2012-08-29 10:06:39Z marcus $
 
1
// $Id: Window.cpp 9357 2014-04-25 15:35:25Z FloSoft $
2
2
//
3
3
// Copyright (c) 2005 - 2011 Settlers Freaks (sf-team at siedler25.org)
4
4
//
29
29
///////////////////////////////////////////////////////////////////////////////
30
30
// Makros / Defines
31
31
#if defined _WIN32 && defined _DEBUG && defined _MSC_VER
32
 
        #define new new(_NORMAL_BLOCK, THIS_FILE, __LINE__)
33
 
        #undef THIS_FILE
34
 
        static char THIS_FILE[] = __FILE__;
 
32
#define new new(_NORMAL_BLOCK, THIS_FILE, __LINE__)
 
33
#undef THIS_FILE
 
34
static char THIS_FILE[] = __FILE__;
35
35
#endif
36
36
 
37
37
///////////////////////////////////////////////////////////////////////////////
41
41
 *  @author OLiver
42
42
 */
43
43
Window::Window(void)
44
 
        : x(0), y(0), width(0), height(0), id(0), parent(NULL), active(false), visible(true), scale(false), tooltip("")
 
44
    : x(0), y(0), width(0), height(0), id(0), parent(NULL), active(false), visible(true), scale(false), tooltip("")
45
45
{
46
46
}
47
47
 
56
56
 *
57
57
 *  @author OLiver
58
58
 */
59
 
Window::Window(unsigned short x, 
60
 
                           unsigned short y, 
61
 
                           unsigned int id, 
62
 
                           Window *parent, 
63
 
                           unsigned short width, 
64
 
                           unsigned short height, 
65
 
                           const std::string& tooltip)
66
 
        : x(x), y(y), width(width), height(height), id(id), parent(parent), active(false), visible(true), scale(false), tooltip(tooltip)
 
59
Window::Window(unsigned short x,
 
60
               unsigned short y,
 
61
               unsigned int id,
 
62
               Window* parent,
 
63
               unsigned short width,
 
64
               unsigned short height,
 
65
               const std::string& tooltip)
 
66
    : x(x), y(y), width(width), height(height), id(id), parent(parent), active(false), visible(true), scale(false), tooltip(tooltip)
67
67
{
68
68
}
69
69
 
75
75
 */
76
76
Window::~Window(void)
77
77
{
78
 
        // Steuerelemente aufräumen
79
 
        for(std::map<unsigned int,Window*>::iterator it = idmap.begin();it != idmap.end();++it)
80
 
                delete it->second;
 
78
    // Steuerelemente aufräumen
 
79
    for(std::map<unsigned int, Window*>::iterator it = idmap.begin(); it != idmap.end(); ++it)
 
80
        delete it->second;
81
81
}
82
82
 
83
83
///////////////////////////////////////////////////////////////////////////////
88
88
 */
89
89
bool Window::Draw(void)
90
90
{
91
 
        if(visible)
92
 
                return Draw_();
 
91
    if(visible)
 
92
        return Draw_();
93
93
 
94
 
        return true;
 
94
    return true;
95
95
}
96
96
 
97
97
///////////////////////////////////////////////////////////////////////////////
106
106
 */
107
107
unsigned short Window::GetX(bool absolute) const
108
108
{
109
 
        if(!absolute)
110
 
                return x;
111
 
 
112
 
        unsigned short abs_x = x;
113
 
        const Window *temp = this;
114
 
 
115
 
        // Relative Koordinaten in absolute umrechnen
116
 
        // ( d.h. Koordinaten von allen Eltern zusammenaddieren )
117
 
        while(temp->parent)
118
 
        {
119
 
                temp = temp->parent;
120
 
                abs_x += temp->x;
121
 
        }
122
 
 
123
 
        return abs_x;
 
109
    if(!absolute)
 
110
        return x;
 
111
 
 
112
    unsigned short abs_x = x;
 
113
    const Window* temp = this;
 
114
 
 
115
    // Relative Koordinaten in absolute umrechnen
 
116
    // ( d.h. Koordinaten von allen Eltern zusammenaddieren )
 
117
    while(temp->parent)
 
118
    {
 
119
        temp = temp->parent;
 
120
        abs_x += temp->x;
 
121
    }
 
122
 
 
123
    return abs_x;
124
124
}
125
125
 
126
126
///////////////////////////////////////////////////////////////////////////////
135
135
 */
136
136
unsigned short Window::GetY(bool absolute) const
137
137
{
138
 
        if(!absolute)
139
 
                return y;
140
 
 
141
 
        unsigned short abs_y = y;
142
 
        const Window *temp = this;
143
 
 
144
 
        // Relative Koordinaten in absolute umrechnen
145
 
        // ( d.h. Koordinaten von allen Eltern zusammenaddieren )
146
 
        while(temp->parent)
147
 
        {
148
 
                temp = temp->parent;
149
 
                abs_y += temp->y;
150
 
        }
151
 
 
152
 
        return abs_y;
 
138
    if(!absolute)
 
139
        return y;
 
140
 
 
141
    unsigned short abs_y = y;
 
142
    const Window* temp = this;
 
143
 
 
144
    // Relative Koordinaten in absolute umrechnen
 
145
    // ( d.h. Koordinaten von allen Eltern zusammenaddieren )
 
146
    while(temp->parent)
 
147
    {
 
148
        temp = temp->parent;
 
149
        abs_y += temp->y;
 
150
    }
 
151
 
 
152
    return abs_y;
153
153
}
154
154
 
155
155
 
163
163
 *
164
164
 *  @author OLiver
165
165
 */
166
 
bool Window::RelayKeyboardMessage(bool (Window::*msg)(const KeyEvent&),const KeyEvent& ke)
 
166
bool Window::RelayKeyboardMessage(bool (Window::*msg)(const KeyEvent&), const KeyEvent& ke)
167
167
{
168
 
        // Abgeleitete Klassen fragen, ob das Weiterleiten von Nachrichten erlaubt ist
169
 
        // (IngameFenster könnten ja z.B. minimiert sein)
170
 
        if(!IsMessageRelayAllowed())
171
 
                return false;
172
 
 
173
 
        // Alle Controls durchgehen
174
 
        // Falls das Fenster dann plötzlich nich mehr aktiv ist (z.b. neues Fenster geöffnet, sofort abbrechen!)
175
 
        for(std::map<unsigned int,Window*>::iterator it = idmap.begin(); it != idmap.end() && active; ++it)
176
 
        {
177
 
                if(it->second->visible && it->second->active)
178
 
                        if((it->second->*msg)(ke))
179
 
                                return true;
180
 
        }
181
 
 
182
 
        return false;
 
168
    // Abgeleitete Klassen fragen, ob das Weiterleiten von Nachrichten erlaubt ist
 
169
    // (IngameFenster könnten ja z.B. minimiert sein)
 
170
    if(!IsMessageRelayAllowed())
 
171
        return false;
 
172
 
 
173
    // Alle Controls durchgehen
 
174
    // Falls das Fenster dann plötzlich nich mehr aktiv ist (z.b. neues Fenster geöffnet, sofort abbrechen!)
 
175
    for(std::map<unsigned int, Window*>::iterator it = idmap.begin(); it != idmap.end() && active; ++it)
 
176
    {
 
177
        if(it->second->visible && it->second->active)
 
178
            if((it->second->*msg)(ke))
 
179
                return true;
 
180
    }
 
181
 
 
182
    return false;
183
183
}
184
184
 
185
 
bool Window::RelayMouseMessage(bool (Window::*msg)(const MouseCoords&),const MouseCoords& mc)
 
185
bool Window::RelayMouseMessage(bool (Window::*msg)(const MouseCoords&), const MouseCoords& mc)
186
186
{
187
 
        // Abgeleitete Klassen fragen, ob das Weiterleiten von Mausnachrichten erlaubt ist
188
 
        // (IngameFenster könnten ja z.B. minimiert sein)
189
 
        if(!IsMessageRelayAllowed())
190
 
                return false;
191
 
 
192
 
        bool processed = false;
193
 
 
194
 
        // Alle Controls durchgehen
195
 
        // Falls das Fenster dann plötzlich nich mehr aktiv ist (z.b. neues Fenster geöffnet, sofort abbrechen!)
196
 
        // Use reverse iterator because the topmost (=last elements) should receive the messages first!
197
 
        for(std::map<unsigned int,Window*>::reverse_iterator it = idmap.rbegin(); it != idmap.rend() && active; ++it)
198
 
        {
199
 
                if(locked_areas.size())
200
 
                        if(TestWindowInRegion(it->second, mc))
201
 
                                continue;
202
 
 
203
 
                if(it->second->visible && it->second->active)
204
 
                        // Falls von einem Steuerelement verarbeitet --> abbrechen
205
 
                        if((it->second->*msg)(mc))
206
 
                        {
207
 
                                processed = true;
208
 
                                break;
209
 
                        }
210
 
        }
211
 
 
212
 
        /*// Nur vorläufig
213
 
        if(processed && msg == &Window::Msg_LeftDown)
214
 
        {
215
 
                for(std::map<unsigned int,Window*>::iterator it = idmap.begin(); it != idmap.end() && active; ++it)
216
 
                {
217
 
                        if(locked_areas.size())
218
 
                                if(TestWindowInRegion(it->second, mc))
219
 
                                        continue;
220
 
 
221
 
                        if(it->second->visible && it->second->active)
222
 
                                // Falls von einem Steuerelement verarbeitet --> abbrechen
223
 
                                it->second->Msg_LeftDown_After(mc);
224
 
 
225
 
                }
226
 
        }*/
227
 
 
228
 
        return processed;
 
187
    // Abgeleitete Klassen fragen, ob das Weiterleiten von Mausnachrichten erlaubt ist
 
188
    // (IngameFenster könnten ja z.B. minimiert sein)
 
189
    if(!IsMessageRelayAllowed())
 
190
        return false;
 
191
 
 
192
    bool processed = false;
 
193
 
 
194
    // Alle Controls durchgehen
 
195
    // Falls das Fenster dann plötzlich nich mehr aktiv ist (z.b. neues Fenster geöffnet, sofort abbrechen!)
 
196
    // Use reverse iterator because the topmost (=last elements) should receive the messages first!
 
197
    for(std::map<unsigned int, Window*>::reverse_iterator it = idmap.rbegin(); it != idmap.rend() && active; ++it)
 
198
    {
 
199
        if(locked_areas.size())
 
200
            if(TestWindowInRegion(it->second, mc))
 
201
                continue;
 
202
 
 
203
        if(it->second->visible && it->second->active)
 
204
            // Falls von einem Steuerelement verarbeitet --> abbrechen
 
205
            if((it->second->*msg)(mc))
 
206
            {
 
207
                processed = true;
 
208
                break;
 
209
            }
 
210
    }
 
211
 
 
212
    /*// Nur vorläufig
 
213
    if(processed && msg == &Window::Msg_LeftDown)
 
214
    {
 
215
        for(std::map<unsigned int,Window*>::iterator it = idmap.begin(); it != idmap.end() && active; ++it)
 
216
        {
 
217
            if(locked_areas.size())
 
218
                if(TestWindowInRegion(it->second, mc))
 
219
                    continue;
 
220
 
 
221
            if(it->second->visible && it->second->active)
 
222
                // Falls von einem Steuerelement verarbeitet --> abbrechen
 
223
                it->second->Msg_LeftDown_After(mc);
 
224
 
 
225
        }
 
226
    }*/
 
227
 
 
228
    return processed;
229
229
}
230
230
 
231
231
///////////////////////////////////////////////////////////////////////////////
238
238
 */
239
239
void Window::SetActive(bool activate)
240
240
{
241
 
        this->active = activate;
242
 
        ActivateControls(activate);
 
241
    this->active = activate;
 
242
    ActivateControls(activate);
243
243
}
244
244
 
245
245
///////////////////////////////////////////////////////////////////////////////
252
252
 */
253
253
void Window::ActivateControls(bool activate)
254
254
{
255
 
        for(std::map<unsigned int,Window*>::iterator it = idmap.begin(); it != idmap.end(); ++it)
256
 
                it->second->SetActive(activate);
 
255
    for(std::map<unsigned int, Window*>::iterator it = idmap.begin(); it != idmap.end(); ++it)
 
256
        it->second->SetActive(activate);
257
257
}
258
258
 
259
259
///////////////////////////////////////////////////////////////////////////////
265
265
 *
266
266
 *  @author OLiver
267
267
 */
268
 
void Window::LockRegion(Window *window, const Rect &rect)
 
268
void Window::LockRegion(Window* window, const Rect& rect)
269
269
{
270
 
        LockedRegion lg = {window, rect};
271
 
        locked_areas.push_back(lg);
 
270
    LockedRegion lg = {window, rect};
 
271
    locked_areas.push_back(lg);
272
272
}
273
273
 
274
274
///////////////////////////////////////////////////////////////////////////////
279
279
 *
280
280
 *  @author OLiver
281
281
 */
282
 
void Window::FreeRegion(Window *window)
 
282
void Window::FreeRegion(Window* window)
283
283
{
284
 
        for(list<LockedRegion>::iterator it = locked_areas.begin(); it.valid(); ++it)
285
 
        {
286
 
                if(window == it->window)
287
 
                {
288
 
                        locked_areas.erase(it);
289
 
                        return;
290
 
                }
291
 
        }
 
284
    for(list<LockedRegion>::iterator it = locked_areas.begin(); it.valid(); ++it)
 
285
    {
 
286
        if(window == it->window)
 
287
        {
 
288
            locked_areas.erase(it);
 
289
            return;
 
290
        }
 
291
    }
292
292
}
293
293
 
294
294
/// Weiterleitung von Nachrichten von abgeleiteten Klassen erlaubt oder nicht?
295
295
bool Window::IsMessageRelayAllowed() const
296
296
{
297
 
        return true;
 
297
    return true;
298
298
}
299
299
 
300
300
///////////////////////////////////////////////////////////////////////////////
303
303
 *
304
304
 *  @author OLiver
305
305
 */
306
 
ctrlBuildingIcon *Window::AddBuildingIcon(unsigned int id, 
307
 
                                                                                  unsigned short x, 
308
 
                                                                                  unsigned short y, 
309
 
                                                                                  BuildingType type,
310
 
                                                                                  const Nation nation,
311
 
                                                                                  unsigned short size,
312
 
                                                                                  const std::string& tooltip)
 
306
ctrlBuildingIcon* Window::AddBuildingIcon(unsigned int id,
 
307
        unsigned short x,
 
308
        unsigned short y,
 
309
        BuildingType type,
 
310
        const Nation nation,
 
311
        unsigned short size,
 
312
        const std::string& tooltip)
313
313
{
314
 
        if(scale)
315
 
        {
316
 
                x = ScaleX(x);
317
 
                y = ScaleY(y);
318
 
        }
 
314
    if(scale)
 
315
    {
 
316
        x = ScaleX(x);
 
317
        y = ScaleY(y);
 
318
    }
319
319
 
320
 
        return AddCtrl(id, new ctrlBuildingIcon(this, id, x, y, type, nation, size, tooltip));
 
320
    return AddCtrl(id, new ctrlBuildingIcon(this, id, x, y, type, nation, size, tooltip));
321
321
}
322
322
 
323
323
///////////////////////////////////////////////////////////////////////////////
340
340
 
341
341
 
342
342
/// fügt einen Text-ButtonCtrl hinzu.
343
 
ctrlTextButton *Window::AddTextButton(unsigned int id, unsigned short x, unsigned short y,unsigned short width, unsigned short height, const TextureColor tc,const std::string& text,  glArchivItem_Font *font, const std::string& tooltip)
 
343
ctrlTextButton* Window::AddTextButton(unsigned int id, unsigned short x, unsigned short y, unsigned short width, unsigned short height, const TextureColor tc, const std::string& text,  glArchivItem_Font* font, const std::string& tooltip)
344
344
{
345
 
        if(scale)
346
 
        {
347
 
                x = ScaleX(x);
348
 
                y = ScaleY(y);
349
 
                width = ScaleX(width);
350
 
                height = ScaleY(height);
351
 
        }
 
345
    if(scale)
 
346
    {
 
347
        x = ScaleX(x);
 
348
        y = ScaleY(y);
 
349
        width = ScaleX(width);
 
350
        height = ScaleY(height);
 
351
    }
352
352
 
353
 
        return AddCtrl(id, new ctrlTextButton(this, id, x, y, width, height, tc, text,font,tooltip));
 
353
    return AddCtrl(id, new ctrlTextButton(this, id, x, y, width, height, tc, text, font, tooltip));
354
354
}
355
355
 
356
356
/// fügt einen Color-ButtonCtrl hinzu.
357
 
ctrlColorButton *Window::AddColorButton(unsigned int id, unsigned short x, unsigned short y,unsigned short width, unsigned short height, const TextureColor tc, const unsigned int fillColor, const std::string& tooltip)
 
357
ctrlColorButton* Window::AddColorButton(unsigned int id, unsigned short x, unsigned short y, unsigned short width, unsigned short height, const TextureColor tc, const unsigned int fillColor, const std::string& tooltip)
358
358
{
359
 
        if(scale)
360
 
        {
361
 
                x = ScaleX(x);
362
 
                y = ScaleY(y);
363
 
                width = ScaleX(width);
364
 
                height = ScaleY(height);
365
 
        }
 
359
    if(scale)
 
360
    {
 
361
        x = ScaleX(x);
 
362
        y = ScaleY(y);
 
363
        width = ScaleX(width);
 
364
        height = ScaleY(height);
 
365
    }
366
366
 
367
 
        return AddCtrl(id, new ctrlColorButton(this, id, x, y, width, height, tc, fillColor, tooltip));
 
367
    return AddCtrl(id, new ctrlColorButton(this, id, x, y, width, height, tc, fillColor, tooltip));
368
368
}
369
369
 
370
370
 
371
371
/// fügt einen Image-ButtonCtrl hinzu.
372
 
ctrlImageButton *Window::AddImageButton(unsigned int id, unsigned short x, unsigned short y,unsigned short width, unsigned short height, const TextureColor tc,glArchivItem_Bitmap * const image,  const std::string& tooltip)
 
372
ctrlImageButton* Window::AddImageButton(unsigned int id, unsigned short x, unsigned short y, unsigned short width, unsigned short height, const TextureColor tc, glArchivItem_Bitmap* const image,  const std::string& tooltip)
373
373
{
374
 
        if(scale)
375
 
        {
376
 
                x = ScaleX(x);
377
 
                y = ScaleY(y);
378
 
                width = ScaleX(width);
379
 
                height = ScaleY(height);
380
 
        }
 
374
    if(scale)
 
375
    {
 
376
        x = ScaleX(x);
 
377
        y = ScaleY(y);
 
378
        width = ScaleX(width);
 
379
        height = ScaleY(height);
 
380
    }
381
381
 
382
 
        return AddCtrl(id, new ctrlImageButton(this, id, x, y, width, height, tc, image,tooltip));
 
382
    return AddCtrl(id, new ctrlImageButton(this, id, x, y, width, height, tc, image, tooltip));
383
383
}
384
384
 
385
385
 
389
389
 *
390
390
 *  @author Devil
391
391
 */
392
 
ctrlChat *Window::AddChatCtrl(unsigned int id,
393
 
                                                          unsigned short x, 
394
 
                                                          unsigned short y,
395
 
                                                          unsigned short width,
396
 
                                                          unsigned short height, 
397
 
                                                          TextureColor tc, 
398
 
                                                          glArchivItem_Font *font)
 
392
ctrlChat* Window::AddChatCtrl(unsigned int id,
 
393
                              unsigned short x,
 
394
                              unsigned short y,
 
395
                              unsigned short width,
 
396
                              unsigned short height,
 
397
                              TextureColor tc,
 
398
                              glArchivItem_Font* font)
399
399
{
400
 
        if(scale)
401
 
        {
402
 
                x = ScaleX(x);
403
 
                y = ScaleY(y);
404
 
                width = ScaleX(width);
405
 
                height = ScaleY(height);
406
 
        }
 
400
    if(scale)
 
401
    {
 
402
        x = ScaleX(x);
 
403
        y = ScaleY(y);
 
404
        width = ScaleX(width);
 
405
        height = ScaleY(height);
 
406
    }
407
407
 
408
 
        return AddCtrl(id, new ctrlChat(this, id, x, y, width, height, tc, font));
 
408
    return AddCtrl(id, new ctrlChat(this, id, x, y, width, height, tc, font));
409
409
}
410
410
 
411
411
///////////////////////////////////////////////////////////////////////////////
414
414
 *
415
415
 *  @author OLiver
416
416
 */
417
 
ctrlCheck *Window::AddCheckBox(unsigned int id,
418
 
                                                           unsigned short x, 
419
 
                                                           unsigned short y,
420
 
                                                           unsigned short width, 
421
 
                                                           unsigned short height,
422
 
                                                           TextureColor tc, 
423
 
                                                           const std::string& text, 
424
 
                                                           glArchivItem_Font *font, 
425
 
                                                           bool readonly)
 
417
ctrlCheck* Window::AddCheckBox(unsigned int id,
 
418
                               unsigned short x,
 
419
                               unsigned short y,
 
420
                               unsigned short width,
 
421
                               unsigned short height,
 
422
                               TextureColor tc,
 
423
                               const std::string& text,
 
424
                               glArchivItem_Font* font,
 
425
                               bool readonly)
426
426
{
427
 
        if(scale)
428
 
        {
429
 
                x = ScaleX(x);
430
 
                y = ScaleY(y);
431
 
                width = ScaleX(width);
432
 
                height = ScaleY(height);
433
 
        }
 
427
    if(scale)
 
428
    {
 
429
        x = ScaleX(x);
 
430
        y = ScaleY(y);
 
431
        width = ScaleX(width);
 
432
        height = ScaleY(height);
 
433
    }
434
434
 
435
 
        return AddCtrl(id, new ctrlCheck(this, id, x, y, width, height, tc, text, font, readonly));
 
435
    return AddCtrl(id, new ctrlCheck(this, id, x, y, width, height, tc, text, font, readonly));
436
436
}
437
437
 
438
438
///////////////////////////////////////////////////////////////////////////////
441
441
 *
442
442
 *  @author OLiver
443
443
 */
444
 
ctrlComboBox *Window::AddComboBox(unsigned int id,
445
 
                                                                  unsigned short x, 
446
 
                                                                  unsigned short y,
447
 
                                                                  unsigned short width,
448
 
                                                                  unsigned short height,
449
 
                                                                  TextureColor tc, 
450
 
                                                                  glArchivItem_Font *font,
451
 
                                                                  unsigned short max_list_height,
452
 
                                                                  bool readonly)
 
444
ctrlComboBox* Window::AddComboBox(unsigned int id,
 
445
                                  unsigned short x,
 
446
                                  unsigned short y,
 
447
                                  unsigned short width,
 
448
                                  unsigned short height,
 
449
                                  TextureColor tc,
 
450
                                  glArchivItem_Font* font,
 
451
                                  unsigned short max_list_height,
 
452
                                  bool readonly)
453
453
{
454
 
        if(scale)
455
 
        {
456
 
                x = ScaleX(x);
457
 
                y = ScaleY(y);
458
 
                width = ScaleX(width);
459
 
                height = ScaleY(height);
460
 
        }
 
454
    if(scale)
 
455
    {
 
456
        x = ScaleX(x);
 
457
        y = ScaleY(y);
 
458
        width = ScaleX(width);
 
459
        height = ScaleY(height);
 
460
    }
461
461
 
462
 
        return AddCtrl(id, new ctrlComboBox(this, id, x, y, width, height, tc, font, max_list_height, readonly));
 
462
    return AddCtrl(id, new ctrlComboBox(this, id, x, y, width, height, tc, font, max_list_height, readonly));
463
463
}
464
464
 
465
465
///////////////////////////////////////////////////////////////////////////////
468
468
 *
469
469
 *  @author OLiver
470
470
 */
471
 
ctrlDeepening *Window::AddDeepening(unsigned int id,
472
 
                                                                        unsigned short x,
473
 
                                                                        unsigned short y,
474
 
                                                                        unsigned short width, 
475
 
                                                                        unsigned short height, 
476
 
                                                                        TextureColor tc, 
477
 
                                                                        const std::string& text, 
478
 
                                                                        glArchivItem_Font *font, 
479
 
                                                                        unsigned int color)
 
471
ctrlDeepening* Window::AddDeepening(unsigned int id,
 
472
                                    unsigned short x,
 
473
                                    unsigned short y,
 
474
                                    unsigned short width,
 
475
                                    unsigned short height,
 
476
                                    TextureColor tc,
 
477
                                    const std::string& text,
 
478
                                    glArchivItem_Font* font,
 
479
                                    unsigned int color)
480
480
{
481
 
        if(scale)
482
 
        {
483
 
                x = ScaleX(x);
484
 
                y = ScaleY(y);
485
 
                width = ScaleX(width);
486
 
                height = ScaleY(height);
487
 
        }
 
481
    if(scale)
 
482
    {
 
483
        x = ScaleX(x);
 
484
        y = ScaleY(y);
 
485
        width = ScaleX(width);
 
486
        height = ScaleY(height);
 
487
    }
488
488
 
489
 
        return AddCtrl(id, new ctrlDeepening(this, id, x, y, width, height, tc, text, font, color));
 
489
    return AddCtrl(id, new ctrlDeepening(this, id, x, y, width, height, tc, text, font, color));
490
490
}
491
491
 
492
492
///////////////////////////////////////////////////////////////////////////////
495
495
 *
496
496
 *  @author Divan
497
497
 */
498
 
ctrlColorDeepening *Window::AddColorDeepening(unsigned int id,
499
 
                                                                        unsigned short x,
500
 
                                                                        unsigned short y,
501
 
                                                                        unsigned short width, 
502
 
                                                                        unsigned short height, 
503
 
                                                                        TextureColor tc, 
504
 
                                                                        unsigned int fillColor)
 
498
ctrlColorDeepening* Window::AddColorDeepening(unsigned int id,
 
499
        unsigned short x,
 
500
        unsigned short y,
 
501
        unsigned short width,
 
502
        unsigned short height,
 
503
        TextureColor tc,
 
504
        unsigned int fillColor)
505
505
{
506
 
        if(scale)
507
 
        {
508
 
                x = ScaleX(x);
509
 
                y = ScaleY(y);
510
 
                width = ScaleX(width);
511
 
                height = ScaleY(height);
512
 
        }
 
506
    if(scale)
 
507
    {
 
508
        x = ScaleX(x);
 
509
        y = ScaleY(y);
 
510
        width = ScaleX(width);
 
511
        height = ScaleY(height);
 
512
    }
513
513
 
514
 
        return AddCtrl(id, new ctrlColorDeepening(this, id, x, y, width, height, tc, fillColor));
 
514
    return AddCtrl(id, new ctrlColorDeepening(this, id, x, y, width, height, tc, fillColor));
515
515
}
516
516
 
517
517
///////////////////////////////////////////////////////////////////////////////
520
520
 *
521
521
 *  @author OLiver
522
522
 */
523
 
ctrlEdit *Window::AddEdit(unsigned int id,
524
 
                                                  unsigned short x, 
525
 
                                                  unsigned short y, 
526
 
                                                  unsigned short width, 
527
 
                                                  unsigned short height, 
528
 
                                                  TextureColor tc, 
529
 
                                                  glArchivItem_Font *font,
530
 
                                                  unsigned short maxlength,
531
 
                                                  bool password, 
532
 
                                                  bool disabled,
533
 
                                                  bool notify)
 
523
ctrlEdit* Window::AddEdit(unsigned int id,
 
524
                          unsigned short x,
 
525
                          unsigned short y,
 
526
                          unsigned short width,
 
527
                          unsigned short height,
 
528
                          TextureColor tc,
 
529
                          glArchivItem_Font* font,
 
530
                          unsigned short maxlength,
 
531
                          bool password,
 
532
                          bool disabled,
 
533
                          bool notify)
534
534
{
535
 
        if(scale)
536
 
        {
537
 
                x = ScaleX(x);
538
 
                y = ScaleY(y);
539
 
                width = ScaleX(width);
540
 
                height = ScaleY(height);
541
 
        }
 
535
    if(scale)
 
536
    {
 
537
        x = ScaleX(x);
 
538
        y = ScaleY(y);
 
539
        width = ScaleX(width);
 
540
        height = ScaleY(height);
 
541
    }
542
542
 
543
 
        return AddCtrl(id, new ctrlEdit(this, id, x, y, width, height, tc, font, maxlength, password, disabled, notify));
 
543
    return AddCtrl(id, new ctrlEdit(this, id, x, y, width, height, tc, font, maxlength, password, disabled, notify));
544
544
}
545
545
 
546
546
///////////////////////////////////////////////////////////////////////////////
549
549
 *
550
550
 *  @author FloSoft
551
551
 */
552
 
ctrlGroup *Window::AddGroup(unsigned int id, bool scale)
 
552
ctrlGroup* Window::AddGroup(unsigned int id, bool scale)
553
553
{
554
 
        return AddCtrl(id, new ctrlGroup(this, id, scale));
 
554
    return AddCtrl(id, new ctrlGroup(this, id, scale));
555
555
}
556
556
 
557
557
///////////////////////////////////////////////////////////////////////////////
560
560
 *
561
561
 *  @author OLiver
562
562
 */
563
 
ctrlImage *Window::AddImage(unsigned int id,
564
 
                                                        unsigned short x,
565
 
                                                        unsigned short y,
566
 
                                                        glArchivItem_Bitmap *image, const std::string& tooltip)
 
563
ctrlImage* Window::AddImage(unsigned int id,
 
564
                            unsigned short x,
 
565
                            unsigned short y,
 
566
                            glArchivItem_Bitmap* image, const std::string& tooltip)
567
567
{
568
 
        if(scale)
569
 
        {
570
 
                x = ScaleX(x);
571
 
                y = ScaleY(y);
572
 
        }
 
568
    if(scale)
 
569
    {
 
570
        x = ScaleX(x);
 
571
        y = ScaleY(y);
 
572
    }
573
573
 
574
 
        return AddCtrl(id, new ctrlImage(this, id, x, y, image, tooltip));
 
574
    return AddCtrl(id, new ctrlImage(this, id, x, y, image, tooltip));
575
575
}
576
576
 
577
577
///////////////////////////////////////////////////////////////////////////////
580
580
 *
581
581
 *  @author OLiver
582
582
 */
583
 
ctrlList *Window::AddList(unsigned int id,
584
 
                                                  unsigned short x,
585
 
                                                  unsigned short y,
586
 
                                                  unsigned short width,
587
 
                                                  unsigned short height,
588
 
                                                  TextureColor tc,
589
 
                                                  glArchivItem_Font *font)
 
583
ctrlList* Window::AddList(unsigned int id,
 
584
                          unsigned short x,
 
585
                          unsigned short y,
 
586
                          unsigned short width,
 
587
                          unsigned short height,
 
588
                          TextureColor tc,
 
589
                          glArchivItem_Font* font)
590
590
{
591
 
        if(scale)
592
 
        {
593
 
                x = ScaleX(x);
594
 
                y = ScaleY(y);
595
 
                width = ScaleX(width);
596
 
                height = ScaleY(height);
597
 
        }
 
591
    if(scale)
 
592
    {
 
593
        x = ScaleX(x);
 
594
        y = ScaleY(y);
 
595
        width = ScaleX(width);
 
596
        height = ScaleY(height);
 
597
    }
598
598
 
599
 
        return AddCtrl(id, new ctrlList(this, id, x, y, width, height, tc, font));
 
599
    return AddCtrl(id, new ctrlList(this, id, x, y, width, height, tc, font));
600
600
}
601
601
 
602
602
///////////////////////////////////////////////////////////////////////////////
605
605
 *
606
606
 *  @author Devil
607
607
 */
608
 
ctrlMultiline *Window::AddMultiline(unsigned int id,
609
 
                                                                        unsigned short x, 
610
 
                                                                    unsigned short y, 
611
 
                                                                    unsigned short width, 
612
 
                                                                    unsigned short height, 
613
 
                                                                    TextureColor tc, 
614
 
                                                                    glArchivItem_Font *font, 
615
 
                                                                        unsigned int format)
 
608
ctrlMultiline* Window::AddMultiline(unsigned int id,
 
609
                                    unsigned short x,
 
610
                                    unsigned short y,
 
611
                                    unsigned short width,
 
612
                                    unsigned short height,
 
613
                                    TextureColor tc,
 
614
                                    glArchivItem_Font* font,
 
615
                                    unsigned int format)
616
616
{
617
 
        if(scale)
618
 
        {
619
 
                x = ScaleX(x);
620
 
                y = ScaleY(y);
621
 
                width = ScaleX(width);
622
 
                height = ScaleY(height);
623
 
        }
 
617
    if(scale)
 
618
    {
 
619
        x = ScaleX(x);
 
620
        y = ScaleY(y);
 
621
        width = ScaleX(width);
 
622
        height = ScaleY(height);
 
623
    }
624
624
 
625
 
        return AddCtrl(id, new ctrlMultiline(this, id, x, y, width, height, tc, font, format));
 
625
    return AddCtrl(id, new ctrlMultiline(this, id, x, y, width, height, tc, font, format));
626
626
}
627
627
 
628
628
///////////////////////////////////////////////////////////////////////////////
636
636
 *
637
637
 *  @author OLiver
638
638
 */
639
 
ctrlOptionGroup *Window::AddOptionGroup(unsigned int id,
640
 
                                                                                int select_type,
641
 
                                                                                bool scale)
 
639
ctrlOptionGroup* Window::AddOptionGroup(unsigned int id,
 
640
                                        int select_type,
 
641
                                        bool scale)
642
642
{
643
 
        return AddCtrl(id, new ctrlOptionGroup(this, id, select_type, scale));
 
643
    return AddCtrl(id, new ctrlOptionGroup(this, id, select_type, scale));
644
644
}
645
645
 
646
646
///////////////////////////////////////////////////////////////////////////////
654
654
 *
655
655
 *  @author jh
656
656
 */
657
 
ctrlMultiSelectGroup *Window::AddMultiSelectGroup(unsigned int id, 
658
 
                                                                                                                                                                                                        int select_type, 
659
 
                                                                                                                                                                                                        bool scale)
 
657
ctrlMultiSelectGroup* Window::AddMultiSelectGroup(unsigned int id,
 
658
        int select_type,
 
659
        bool scale)
660
660
{
661
 
        return AddCtrl(id, new ctrlMultiSelectGroup(this, id, select_type, scale));
 
661
    return AddCtrl(id, new ctrlMultiSelectGroup(this, id, select_type, scale));
662
662
}
663
663
 
664
664
///////////////////////////////////////////////////////////////////////////////
667
667
 *
668
668
 *  @author OLiver
669
669
 */
670
 
ctrlPercent *Window::AddPercent(unsigned int id,
671
 
                                                                unsigned short x,
672
 
                                                                unsigned short y, 
673
 
                                                                unsigned short width,
674
 
                                                                unsigned short height,
675
 
                                                                TextureColor tc, 
676
 
                                                                unsigned int text_color, 
677
 
                                                                glArchivItem_Font *font,
678
 
                                                                const unsigned short *percentage)
 
670
ctrlPercent* Window::AddPercent(unsigned int id,
 
671
                                unsigned short x,
 
672
                                unsigned short y,
 
673
                                unsigned short width,
 
674
                                unsigned short height,
 
675
                                TextureColor tc,
 
676
                                unsigned int text_color,
 
677
                                glArchivItem_Font* font,
 
678
                                const unsigned short* percentage)
679
679
{
680
 
        if(scale)
681
 
        {
682
 
                x = ScaleX(x);
683
 
                y = ScaleY(y);
684
 
                width = ScaleX(width);
685
 
                height = ScaleY(height);
686
 
        }
 
680
    if(scale)
 
681
    {
 
682
        x = ScaleX(x);
 
683
        y = ScaleY(y);
 
684
        width = ScaleX(width);
 
685
        height = ScaleY(height);
 
686
    }
687
687
 
688
 
        return AddCtrl(id, new ctrlPercent(this, id, x, y, width, height, tc, text_color, font, percentage));
 
688
    return AddCtrl(id, new ctrlPercent(this, id, x, y, width, height, tc, text_color, font, percentage));
689
689
}
690
690
 
691
691
///////////////////////////////////////////////////////////////////////////////
694
694
 *
695
695
 *  @author OLiver
696
696
 */
697
 
ctrlProgress *Window::AddProgress(unsigned int id,
698
 
                                                                  unsigned short x,
699
 
                                                                  unsigned short y,
700
 
                                                                  unsigned short width,
701
 
                                                                  unsigned short height,
702
 
                                                                  TextureColor tc,
703
 
                                                                  unsigned short button_minus,
704
 
                                                                  unsigned short button_plus,
705
 
                                                                  unsigned short maximum,
706
 
                                                                  const std::string& tooltip,
707
 
                                                                  unsigned short x_padding,
708
 
                                                                  unsigned short y_padding,
709
 
                                                                  unsigned int force_color,
710
 
                                                                  const std::string& button_minus_tooltip,
711
 
                                                                  const std::string& button_plus_tooltip)
 
697
ctrlProgress* Window::AddProgress(unsigned int id,
 
698
                                  unsigned short x,
 
699
                                  unsigned short y,
 
700
                                  unsigned short width,
 
701
                                  unsigned short height,
 
702
                                  TextureColor tc,
 
703
                                  unsigned short button_minus,
 
704
                                  unsigned short button_plus,
 
705
                                  unsigned short maximum,
 
706
                                  const std::string& tooltip,
 
707
                                  unsigned short x_padding,
 
708
                                  unsigned short y_padding,
 
709
                                  unsigned int force_color,
 
710
                                  const std::string& button_minus_tooltip,
 
711
                                  const std::string& button_plus_tooltip)
712
712
{
713
 
        if(scale)
714
 
        {
715
 
                x = ScaleX(x);
716
 
                y = ScaleY(y);
717
 
                width = ScaleX(width);
718
 
                height = ScaleY(height);
719
 
        }
 
713
    if(scale)
 
714
    {
 
715
        x = ScaleX(x);
 
716
        y = ScaleY(y);
 
717
        width = ScaleX(width);
 
718
        height = ScaleY(height);
 
719
    }
720
720
 
721
 
        return AddCtrl(id, new ctrlProgress(this, id, x, y, width, height, tc, button_minus, button_plus, maximum, x_padding, y_padding, force_color, tooltip, button_minus_tooltip, button_plus_tooltip));
 
721
    return AddCtrl(id, new ctrlProgress(this, id, x, y, width, height, tc, button_minus, button_plus, maximum, x_padding, y_padding, force_color, tooltip, button_minus_tooltip, button_plus_tooltip));
722
722
}
723
723
 
724
724
///////////////////////////////////////////////////////////////////////////////
727
727
 *
728
728
 *  @author OLiver
729
729
 */
730
 
ctrlScrollBar *Window::AddScrollBar(unsigned int id,
731
 
                                                          unsigned short x, 
732
 
                                                          unsigned short y,
733
 
                                                          unsigned short width, 
734
 
                                                          unsigned short height, 
735
 
                                                          unsigned short button_height, 
736
 
                                                          TextureColor tc, 
737
 
                                                          unsigned short page_size)
 
730
ctrlScrollBar* Window::AddScrollBar(unsigned int id,
 
731
                                    unsigned short x,
 
732
                                    unsigned short y,
 
733
                                    unsigned short width,
 
734
                                    unsigned short height,
 
735
                                    unsigned short button_height,
 
736
                                    TextureColor tc,
 
737
                                    unsigned short page_size)
738
738
{
739
 
        if(scale)
740
 
        {
741
 
                x = ScaleX(x);
742
 
                y = ScaleY(y);
743
 
                width = ScaleX(width);
744
 
                height = ScaleY(height);
745
 
                button_height = ScaleY(button_height);
746
 
        }
 
739
    if(scale)
 
740
    {
 
741
        x = ScaleX(x);
 
742
        y = ScaleY(y);
 
743
        width = ScaleX(width);
 
744
        height = ScaleY(height);
 
745
        button_height = ScaleY(button_height);
 
746
    }
747
747
 
748
 
        return AddCtrl(id, new ctrlScrollBar(this, id, x, y, width, height, button_height, tc, page_size));
 
748
    return AddCtrl(id, new ctrlScrollBar(this, id, x, y, width, height, button_height, tc, page_size));
749
749
}
750
750
 
751
751
///////////////////////////////////////////////////////////////////////////////
754
754
 *
755
755
 *  @author OLiver
756
756
 */
757
 
ctrlTab *Window::AddTabCtrl(unsigned int id,
758
 
                                                unsigned short x, 
759
 
                                                unsigned short y, 
760
 
                                                unsigned short width)
 
757
ctrlTab* Window::AddTabCtrl(unsigned int id,
 
758
                            unsigned short x,
 
759
                            unsigned short y,
 
760
                            unsigned short width)
761
761
{
762
 
        if(scale)
763
 
        {
764
 
                x = ScaleX(x);
765
 
                y = ScaleY(y);
766
 
                width = ScaleX(width);
767
 
        }
 
762
    if(scale)
 
763
    {
 
764
        x = ScaleX(x);
 
765
        y = ScaleY(y);
 
766
        width = ScaleX(width);
 
767
    }
768
768
 
769
 
        return AddCtrl(id, new ctrlTab(this, id, x, y, width));
 
769
    return AddCtrl(id, new ctrlTab(this, id, x, y, width));
770
770
}
771
771
 
772
772
///////////////////////////////////////////////////////////////////////////////
776
776
 *
777
777
 *  @author OLiver
778
778
 */
779
 
ctrlTable *Window::AddTable(unsigned int id,
780
 
                                                        unsigned short x, 
781
 
                                                        unsigned short y, 
782
 
                                                        unsigned short width, 
783
 
                                                        unsigned short height, 
784
 
                                                        TextureColor tc, 
785
 
                                                        glArchivItem_Font *font, 
786
 
                                                        unsigned int columns, 
787
 
                                                        ...)
 
779
ctrlTable* Window::AddTable(unsigned int id,
 
780
                            unsigned short x,
 
781
                            unsigned short y,
 
782
                            unsigned short width,
 
783
                            unsigned short height,
 
784
                            TextureColor tc,
 
785
                            glArchivItem_Font* font,
 
786
                            unsigned int columns,
 
787
                            ...)
788
788
{
789
 
        ctrlTable *ctrl;
790
 
        va_list liste;
791
 
        va_start(liste, columns);
792
 
 
793
 
        if(scale)
794
 
        {
795
 
                x = ScaleX(x);
796
 
                y = ScaleY(y);
797
 
                width = ScaleX(width);
798
 
                height = ScaleY(height);
799
 
        }
800
 
 
801
 
        ctrl = new ctrlTable(this, id, x, y, width, height, tc, font, columns, liste);
802
 
        
803
 
        va_end(liste);
804
 
 
805
 
        return AddCtrl(id, ctrl);
 
789
    ctrlTable* ctrl;
 
790
    va_list liste;
 
791
    va_start(liste, columns);
 
792
 
 
793
    if(scale)
 
794
    {
 
795
        x = ScaleX(x);
 
796
        y = ScaleY(y);
 
797
        width = ScaleX(width);
 
798
        height = ScaleY(height);
 
799
    }
 
800
 
 
801
    ctrl = new ctrlTable(this, id, x, y, width, height, tc, font, columns, liste);
 
802
 
 
803
    va_end(liste);
 
804
 
 
805
    return AddCtrl(id, ctrl);
806
806
}
807
807
 
808
808
///////////////////////////////////////////////////////////////////////////////
811
811
 *
812
812
 *  @author FloSoft
813
813
 */
814
 
ctrlTimer *Window::AddTimer(unsigned int id, unsigned int timeout)
 
814
ctrlTimer* Window::AddTimer(unsigned int id, unsigned int timeout)
815
815
{
816
 
        return AddCtrl(id, new ctrlTimer(this, id, timeout));
 
816
    return AddCtrl(id, new ctrlTimer(this, id, timeout));
817
817
}
818
818
 
819
819
///////////////////////////////////////////////////////////////////////////////
835
835
 *
836
836
 *  @author OLiver
837
837
 */
838
 
ctrlText *Window::AddText(unsigned int id, 
839
 
                                                  unsigned short x,
840
 
                                                  unsigned short y, 
841
 
                                                  const std::string& text, 
842
 
                                                  unsigned int color, 
843
 
                                                  unsigned int format, 
844
 
                                                  glArchivItem_Font *font)
 
838
ctrlText* Window::AddText(unsigned int id,
 
839
                          unsigned short x,
 
840
                          unsigned short y,
 
841
                          const std::string& text,
 
842
                          unsigned int color,
 
843
                          unsigned int format,
 
844
                          glArchivItem_Font* font)
845
845
{
846
 
        if(scale)
847
 
        {
848
 
                x = ScaleX(x);
849
 
                y = ScaleY(y);
850
 
        }
 
846
    if(scale)
 
847
    {
 
848
        x = ScaleX(x);
 
849
        y = ScaleY(y);
 
850
    }
851
851
 
852
 
        return AddCtrl(id, new ctrlText(this, id, x, y, text, color, format, font));
 
852
    return AddCtrl(id, new ctrlText(this, id, x, y, text, color, format, font));
853
853
}
854
854
 
855
855
///////////////////////////////////////////////////////////////////////////////
858
858
 *
859
859
 *  @author FloSoft
860
860
 */
861
 
ctrlVarDeepening *Window::AddVarDeepening(unsigned int id, 
862
 
                                                                         unsigned short x, 
863
 
                                                                         unsigned short y, 
864
 
                                                                         unsigned short width, 
865
 
                                                                         unsigned short height, 
866
 
                                                                         TextureColor tc, 
867
 
                                                                         const std::string& formatstr,  
868
 
                                                                         glArchivItem_Font *font,
869
 
                                                                         unsigned int color,
870
 
                                                                         unsigned int parameters, 
871
 
                                                                         ...)
 
861
ctrlVarDeepening* Window::AddVarDeepening(unsigned int id,
 
862
        unsigned short x,
 
863
        unsigned short y,
 
864
        unsigned short width,
 
865
        unsigned short height,
 
866
        TextureColor tc,
 
867
        const std::string& formatstr,
 
868
        glArchivItem_Font* font,
 
869
        unsigned int color,
 
870
        unsigned int parameters,
 
871
        ...)
872
872
{
873
 
        ctrlVarDeepening *ctrl;
874
 
        va_list liste;
875
 
        va_start(liste, parameters);
876
 
 
877
 
        if(scale)
878
 
        {
879
 
                x = ScaleX(x);
880
 
                y = ScaleY(y);
881
 
                width = ScaleX(width);
882
 
                height = ScaleY(height);
883
 
        }
884
 
 
885
 
        ctrl = new ctrlVarDeepening(this, id, x, y, width, height, tc, formatstr, font, color, parameters, liste);
886
 
        
887
 
        va_end(liste);
888
 
 
889
 
        return AddCtrl(id, ctrl);
 
873
    ctrlVarDeepening* ctrl;
 
874
    va_list liste;
 
875
    va_start(liste, parameters);
 
876
 
 
877
    if(scale)
 
878
    {
 
879
        x = ScaleX(x);
 
880
        y = ScaleY(y);
 
881
        width = ScaleX(width);
 
882
        height = ScaleY(height);
 
883
    }
 
884
 
 
885
    ctrl = new ctrlVarDeepening(this, id, x, y, width, height, tc, formatstr, font, color, parameters, liste);
 
886
 
 
887
    va_end(liste);
 
888
 
 
889
    return AddCtrl(id, ctrl);
890
890
}
891
891
 
892
892
///////////////////////////////////////////////////////////////////////////////
910
910
 *
911
911
 *  @author OLiver
912
912
 */
913
 
ctrlVarText *Window::AddVarText(unsigned int id, 
914
 
                                                                unsigned short x, 
915
 
                                                                unsigned short y, 
916
 
                                                                 const std::string& formatstr, 
917
 
                                                                unsigned int color, 
918
 
                                                                unsigned int format, 
919
 
                                                                glArchivItem_Font *font, 
920
 
                                                                unsigned int parameters, 
921
 
                                                                ...)
 
913
ctrlVarText* Window::AddVarText(unsigned int id,
 
914
                                unsigned short x,
 
915
                                unsigned short y,
 
916
                                const std::string& formatstr,
 
917
                                unsigned int color,
 
918
                                unsigned int format,
 
919
                                glArchivItem_Font* font,
 
920
                                unsigned int parameters,
 
921
                                ...)
922
922
{
923
 
        ctrlVarText *ctrl;
924
 
        va_list liste;
925
 
        va_start(liste, parameters);
926
 
 
927
 
        if(scale)
928
 
        {
929
 
                x = ScaleX(x);
930
 
                y = ScaleY(y);
931
 
        }
932
 
 
933
 
        ctrl = new ctrlVarText(this, id, x, y, formatstr, color, format, font, parameters, liste);
934
 
        
935
 
        va_end(liste);
936
 
 
937
 
        return AddCtrl(id, ctrl);
 
923
    ctrlVarText* ctrl;
 
924
    va_list liste;
 
925
    va_start(liste, parameters);
 
926
 
 
927
    if(scale)
 
928
    {
 
929
        x = ScaleX(x);
 
930
        y = ScaleY(y);
 
931
    }
 
932
 
 
933
    ctrl = new ctrlVarText(this, id, x, y, formatstr, color, format, font, parameters, liste);
 
934
 
 
935
    va_end(liste);
 
936
 
 
937
    return AddCtrl(id, ctrl);
938
938
}
939
939
 
940
 
ctrlPreviewMinimap *Window::AddPreviewMinimap(const unsigned id,
941
 
                                 unsigned short x, 
942
 
                                 unsigned short y, 
943
 
                                  unsigned short width, 
944
 
                                  unsigned short height,
945
 
                                 glArchivItem_Map * const map)
 
940
ctrlPreviewMinimap* Window::AddPreviewMinimap(const unsigned id,
 
941
        unsigned short x,
 
942
        unsigned short y,
 
943
        unsigned short width,
 
944
        unsigned short height,
 
945
        glArchivItem_Map* const map)
946
946
{
947
 
        if(scale)
948
 
        {
949
 
                x = ScaleX(x);
950
 
                y = ScaleY(y);
951
 
                width = ScaleX(width);
952
 
                height = ScaleY(height);
953
 
        }
 
947
    if(scale)
 
948
    {
 
949
        x = ScaleX(x);
 
950
        y = ScaleY(y);
 
951
        width = ScaleX(width);
 
952
        height = ScaleY(height);
 
953
    }
954
954
 
955
 
        return AddCtrl(id, new ctrlPreviewMinimap(this, id, x, y, width, height, map));
 
955
    return AddCtrl(id, new ctrlPreviewMinimap(this, id, x, y, width, height, map));
956
956
}
957
957
 
958
958
///////////////////////////////////////////////////////////////////////////////
961
961
 *
962
962
 *  @author OLiver
963
963
 */
964
 
void Window::Draw3D(const unsigned short x, 
965
 
                        const unsigned short y, 
966
 
                        const unsigned short width, 
967
 
                        const unsigned short height,
968
 
                        const TextureColor tc,
969
 
                        const unsigned short type,
970
 
                        const bool illuminated,
971
 
                        const bool draw_content)
 
964
void Window::Draw3D(const unsigned short x,
 
965
                    const unsigned short y,
 
966
                    const unsigned short width,
 
967
                    const unsigned short height,
 
968
                    const TextureColor tc,
 
969
                    const unsigned short type,
 
970
                    const bool illuminated,
 
971
                    const bool draw_content)
972
972
{
973
 
        if(width < 4 || height < 4)
974
 
                return;
975
 
 
976
 
        if(type <= 1)
977
 
        {
978
 
                // Äußerer Rahmen
979
 
                LOADER.GetImageN("io", 12 + tc)->Draw(x, y, width, 2,      0, 0, width, 2);
980
 
                LOADER.GetImageN("io", 12 + tc)->Draw(x, y, 2,     height, 0, 0, 2,     height);
981
 
 
982
 
                if(illuminated)
983
 
                {
984
 
                        // Modulate2x anmachen
985
 
                        glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_COMBINE_EXT);
986
 
                        glTexEnvf(GL_TEXTURE_ENV, GL_RGB_SCALE_EXT, 2.0f);
987
 
                }
988
 
 
989
 
                // Inhalt der Box
990
 
                if(draw_content)
991
 
                {
992
 
                        if(type)
993
 
                                LOADER.GetImageN("io", tc*2)->Draw(x+2,y+2,width-4,height-4,0, 0, width-4,height-4);
994
 
                        else
995
 
                                LOADER.GetImageN("io", tc*2+1)->Draw(x+2,y+2,width-4,height-4,0, 0, width-4,height-4);
996
 
                }
997
 
 
998
 
                if(illuminated)
999
 
                {
1000
 
                        // Modulate2x wieder ausmachen
1001
 
                        glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
1002
 
                }
1003
 
 
1004
 
                glDisable(GL_TEXTURE_2D);
1005
 
 
1006
 
                glColor3f(0.0f,0.0f,0.0f);
1007
 
 
1008
 
                glBegin(GL_QUADS);
1009
 
 
1010
 
                glVertex2i(x+width-1,y);
1011
 
                glVertex2i(x+width-1,y+height);
1012
 
                glVertex2i(x+width,y+height);
1013
 
                glVertex2i(x+width,y);
1014
 
 
1015
 
                glVertex2i(x+width-2,y+1);
1016
 
                glVertex2i(x+width-2,y+height);
1017
 
                glVertex2i(x+width-1,y+height);
1018
 
                glVertex2i(x+width-1,y+1);
1019
 
 
1020
 
                glVertex2i(x,y+height-1);
1021
 
                glVertex2i(x,y+height);
1022
 
                glVertex2i(x+width-2,y+height);
1023
 
                glVertex2i(x+width-2,y+height-1);
1024
 
 
1025
 
                glVertex2i(x+1,y+height-2);
1026
 
                glVertex2i(x+1,y+height-1);
1027
 
                glVertex2i(x+width-2,y+height-1);
1028
 
                glVertex2i(x+width-2,y+height-2);
1029
 
 
1030
 
                glEnd();
1031
 
        }
1032
 
        else
1033
 
        {
1034
 
                LOADER.GetImageN("io",12+tc)->Draw(x,y+height-2,width,2,0, 0, width,2);
1035
 
                LOADER.GetImageN("io",12+tc)->Draw(x+width-2,y, 2,height,0, 0,2,height);
1036
 
 
1037
 
                if(illuminated)
1038
 
                {
1039
 
                        // Modulate2x anmachen
1040
 
                        glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_COMBINE_EXT);
1041
 
                        glTexEnvf(GL_TEXTURE_ENV, GL_RGB_SCALE_EXT, 2.0f);
1042
 
                }
1043
 
 
1044
 
                LOADER.GetImageN("io",tc*2+1)->Draw(x+2,y+2,width-4,2,0, 0, width-4,2);
1045
 
                LOADER.GetImageN("io",tc*2+1)->Draw(x+2,y+2,2,height-4,0, 0, 2,height-4);
1046
 
 
1047
 
                LOADER.GetImageN("io",tc*2+1)->Draw(x+4,y+4,width-6,height-6,0, 0, width-6,height-6);
1048
 
 
1049
 
                if(illuminated)
1050
 
                {
1051
 
                        // Modulate2x wieder ausmachen
1052
 
                        glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
1053
 
                }
1054
 
 
1055
 
                glDisable(GL_TEXTURE_2D);
1056
 
 
1057
 
                glColor3f(0.0f,0.0f,0.0f);
1058
 
 
1059
 
                glBegin(GL_QUADS);
1060
 
 
1061
 
                glVertex2i(x,y);
1062
 
                glVertex2i(x,y+1);
1063
 
                glVertex2i(x+width,y+1);
1064
 
                glVertex2i(x+width,y);
1065
 
 
1066
 
                glVertex2i(x,y+1);
1067
 
                glVertex2i(x,y+2);
1068
 
                glVertex2i(x+width-1,y+2);
1069
 
                glVertex2i(x+width-1,y+1);
1070
 
 
1071
 
                glVertex2i(x,y+2);
1072
 
                glVertex2i(x,y+height);
1073
 
                glVertex2i(x+1,y+height);
1074
 
                glVertex2i(x+1,y+2);
1075
 
 
1076
 
                glVertex2i(x+1,y+2);
1077
 
                glVertex2i(x+1,y+height-1);
1078
 
                glVertex2i(x+2,y+height-1);
1079
 
                glVertex2i(x+2,y+2);
1080
 
 
1081
 
                glEnd();
1082
 
        }
1083
 
 
1084
 
        glEnable(GL_TEXTURE_2D);
 
973
    if(width < 4 || height < 4)
 
974
        return;
 
975
 
 
976
    if(type <= 1)
 
977
    {
 
978
        // Äußerer Rahmen
 
979
        LOADER.GetImageN("io", 12 + tc)->Draw(x, y, width, 2,      0, 0, width, 2);
 
980
        LOADER.GetImageN("io", 12 + tc)->Draw(x, y, 2,     height, 0, 0, 2,     height);
 
981
 
 
982
        if(illuminated)
 
983
        {
 
984
            // Modulate2x anmachen
 
985
            glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_COMBINE_EXT);
 
986
            glTexEnvf(GL_TEXTURE_ENV, GL_RGB_SCALE_EXT, 2.0f);
 
987
        }
 
988
 
 
989
        // Inhalt der Box
 
990
        if(draw_content)
 
991
        {
 
992
            if(type)
 
993
                LOADER.GetImageN("io", tc * 2)->Draw(x + 2, y + 2, width - 4, height - 4, 0, 0, width - 4, height - 4);
 
994
            else
 
995
                LOADER.GetImageN("io", tc * 2 + 1)->Draw(x + 2, y + 2, width - 4, height - 4, 0, 0, width - 4, height - 4);
 
996
        }
 
997
 
 
998
        if(illuminated)
 
999
        {
 
1000
            // Modulate2x wieder ausmachen
 
1001
            glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
 
1002
        }
 
1003
 
 
1004
        glDisable(GL_TEXTURE_2D);
 
1005
 
 
1006
        glColor3f(0.0f, 0.0f, 0.0f);
 
1007
 
 
1008
        glBegin(GL_QUADS);
 
1009
 
 
1010
        glVertex2i(x + width - 1, y);
 
1011
        glVertex2i(x + width - 1, y + height);
 
1012
        glVertex2i(x + width, y + height);
 
1013
        glVertex2i(x + width, y);
 
1014
 
 
1015
        glVertex2i(x + width - 2, y + 1);
 
1016
        glVertex2i(x + width - 2, y + height);
 
1017
        glVertex2i(x + width - 1, y + height);
 
1018
        glVertex2i(x + width - 1, y + 1);
 
1019
 
 
1020
        glVertex2i(x, y + height - 1);
 
1021
        glVertex2i(x, y + height);
 
1022
        glVertex2i(x + width - 2, y + height);
 
1023
        glVertex2i(x + width - 2, y + height - 1);
 
1024
 
 
1025
        glVertex2i(x + 1, y + height - 2);
 
1026
        glVertex2i(x + 1, y + height - 1);
 
1027
        glVertex2i(x + width - 2, y + height - 1);
 
1028
        glVertex2i(x + width - 2, y + height - 2);
 
1029
 
 
1030
        glEnd();
 
1031
    }
 
1032
    else
 
1033
    {
 
1034
        LOADER.GetImageN("io", 12 + tc)->Draw(x, y + height - 2, width, 2, 0, 0, width, 2);
 
1035
        LOADER.GetImageN("io", 12 + tc)->Draw(x + width - 2, y, 2, height, 0, 0, 2, height);
 
1036
 
 
1037
        if(illuminated)
 
1038
        {
 
1039
            // Modulate2x anmachen
 
1040
            glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_COMBINE_EXT);
 
1041
            glTexEnvf(GL_TEXTURE_ENV, GL_RGB_SCALE_EXT, 2.0f);
 
1042
        }
 
1043
 
 
1044
        LOADER.GetImageN("io", tc * 2 + 1)->Draw(x + 2, y + 2, width - 4, 2, 0, 0, width - 4, 2);
 
1045
        LOADER.GetImageN("io", tc * 2 + 1)->Draw(x + 2, y + 2, 2, height - 4, 0, 0, 2, height - 4);
 
1046
 
 
1047
        LOADER.GetImageN("io", tc * 2 + 1)->Draw(x + 4, y + 4, width - 6, height - 6, 0, 0, width - 6, height - 6);
 
1048
 
 
1049
        if(illuminated)
 
1050
        {
 
1051
            // Modulate2x wieder ausmachen
 
1052
            glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
 
1053
        }
 
1054
 
 
1055
        glDisable(GL_TEXTURE_2D);
 
1056
 
 
1057
        glColor3f(0.0f, 0.0f, 0.0f);
 
1058
 
 
1059
        glBegin(GL_QUADS);
 
1060
 
 
1061
        glVertex2i(x, y);
 
1062
        glVertex2i(x, y + 1);
 
1063
        glVertex2i(x + width, y + 1);
 
1064
        glVertex2i(x + width, y);
 
1065
 
 
1066
        glVertex2i(x, y + 1);
 
1067
        glVertex2i(x, y + 2);
 
1068
        glVertex2i(x + width - 1, y + 2);
 
1069
        glVertex2i(x + width - 1, y + 1);
 
1070
 
 
1071
        glVertex2i(x, y + 2);
 
1072
        glVertex2i(x, y + height);
 
1073
        glVertex2i(x + 1, y + height);
 
1074
        glVertex2i(x + 1, y + 2);
 
1075
 
 
1076
        glVertex2i(x + 1, y + 2);
 
1077
        glVertex2i(x + 1, y + height - 1);
 
1078
        glVertex2i(x + 2, y + height - 1);
 
1079
        glVertex2i(x + 2, y + 2);
 
1080
 
 
1081
        glEnd();
 
1082
    }
 
1083
 
 
1084
    glEnable(GL_TEXTURE_2D);
1085
1085
}
1086
1086
 
1087
1087
///////////////////////////////////////////////////////////////////////////////
1094
1094
 */
1095
1095
void Window::DrawRectangle(unsigned short x, unsigned short y, unsigned short width, unsigned short height, unsigned int color)
1096
1096
{
1097
 
        glDisable(GL_TEXTURE_2D);
1098
 
 
1099
 
        glColor4ub(GetRed(color), GetGreen(color), GetBlue(color), GetAlpha(color));
1100
 
 
1101
 
        glBegin(GL_QUADS);
1102
 
        glVertex2i(x, y);
1103
 
        glVertex2i(x, y+height);
1104
 
        glVertex2i(x+width, y+height);
1105
 
        glVertex2i(x+width, y);
1106
 
        glEnd();
1107
 
 
1108
 
        glEnable(GL_TEXTURE_2D);
 
1097
    glDisable(GL_TEXTURE_2D);
 
1098
 
 
1099
    glColor4ub(GetRed(color), GetGreen(color), GetBlue(color), GetAlpha(color));
 
1100
 
 
1101
    glBegin(GL_QUADS);
 
1102
    glVertex2i(x, y);
 
1103
    glVertex2i(x, y + height);
 
1104
    glVertex2i(x + width, y + height);
 
1105
    glVertex2i(x + width, y);
 
1106
    glEnd();
 
1107
 
 
1108
    glEnable(GL_TEXTURE_2D);
1109
1109
}
1110
1110
 
1111
1111
///////////////////////////////////////////////////////////////////////////////
1128
1128
    glEnd();
1129
1129
 
1130
1130
    glEnable(GL_TEXTURE_2D);
1131
 
}  
 
1131
}
1132
1132
 
1133
1133
///////////////////////////////////////////////////////////////////////////////
1134
1134
/**
1138
1138
 */
1139
1139
void Window::DrawControls(void)
1140
1140
{
1141
 
        for(std::map<unsigned int,Window*>::iterator it = idmap.begin(); it != idmap.end(); ++it)
1142
 
        {
1143
 
                Window *control = it->second;
1144
 
                assert(control);
1145
 
 
1146
 
                control->Msg_PaintBefore();
1147
 
                control->Draw();
1148
 
        }
1149
 
 
1150
 
        for(std::map<unsigned int,Window*>::iterator it = idmap.begin(); it != idmap.end(); ++it)
1151
 
        {
1152
 
                Window *control = it->second;
1153
 
                assert(control);
1154
 
 
1155
 
                control->Msg_PaintAfter();
1156
 
        }
 
1141
    for(std::map<unsigned int, Window*>::iterator it = idmap.begin(); it != idmap.end(); ++it)
 
1142
    {
 
1143
        Window* control = it->second;
 
1144
        assert(control);
 
1145
 
 
1146
        control->Msg_PaintBefore();
 
1147
        control->Draw();
 
1148
    }
 
1149
 
 
1150
    for(std::map<unsigned int, Window*>::iterator it = idmap.begin(); it != idmap.end(); ++it)
 
1151
    {
 
1152
        Window* control = it->second;
 
1153
        assert(control);
 
1154
 
 
1155
        control->Msg_PaintAfter();
 
1156
    }
1157
1157
}
1158
1158
 
1159
1159
///////////////////////////////////////////////////////////////////////////////
1168
1168
 *
1169
1169
 *  @author OLiver
1170
1170
 */
1171
 
bool Window::TestWindowInRegion(Window *window, const MouseCoords& mc)
 
1171
bool Window::TestWindowInRegion(Window* window, const MouseCoords& mc)
1172
1172
{
1173
 
        for(list<LockedRegion>::iterator it = locked_areas.begin(); it.valid(); ++it)
1174
 
        {
1175
 
                if(it->window != window && Coll(mc.x + GetX(), mc.y + GetY(), it->rect))
1176
 
                        return true;
1177
 
        }
 
1173
    for(list<LockedRegion>::iterator it = locked_areas.begin(); it.valid(); ++it)
 
1174
    {
 
1175
        if(it->window != window && Coll(mc.x + GetX(), mc.y + GetY(), it->rect))
 
1176
            return true;
 
1177
    }
1178
1178
 
1179
 
        return false;
 
1179
    return false;
1180
1180
}
1181
1181
 
1182
1182
///////////////////////////////////////////////////////////////////////////////
1187
1187
 */
1188
1188
unsigned short Window::ScaleX(unsigned short val) const
1189
1189
{
1190
 
        return  val*VideoDriverWrapper::inst().GetScreenWidth()/800;
 
1190
    return  val * VideoDriverWrapper::inst().GetScreenWidth() / 800;
1191
1191
}
1192
1192
 
1193
1193
unsigned short Window::ScaleY(unsigned short val) const
1194
1194
{
1195
 
        return val*VideoDriverWrapper::inst().GetScreenHeight()/600;
 
1195
    return val * VideoDriverWrapper::inst().GetScreenHeight() / 600;
1196
1196
}
1197
1197
 
1198
1198
 
1199
1199
///////////////////////////////////////////////////////////////////////////////
1200
1200
/**
1201
 
 *  
 
1201
 *
1202
1202
 *
1203
1203
 *  @author OLiver
1204
1204
 */
1205
 
void Window::Msg_PaintBefore() 
 
1205
void Window::Msg_PaintBefore()
1206
1206
{
1207
1207
}
1208
1208
 
1209
1209
///////////////////////////////////////////////////////////////////////////////
1210
1210
/**
1211
 
 *  
 
1211
 *
1212
1212
 *
1213
1213
 *  @author OLiver
1214
1214
 */
1218
1218
 
1219
1219
///////////////////////////////////////////////////////////////////////////////
1220
1220
/**
1221
 
 *  
 
1221
 *
1222
1222
 *
1223
1223
 *  @author OLiver
1224
1224
 */
1225
1225
bool Window::Msg_LeftDown(const MouseCoords& mc)
1226
1226
{
1227
 
        return false;
 
1227
    return false;
1228
1228
}
1229
1229
 
1230
1230
///////////////////////////////////////////////////////////////////////////////
1231
1231
/**
1232
 
 *  
 
1232
 *
1233
1233
 *
1234
1234
 *  @author OLiver
1235
1235
 */
1236
1236
bool Window::Msg_RightDown(const MouseCoords& mc)
1237
1237
{
1238
 
        return false;
 
1238
    return false;
1239
1239
}
1240
1240
 
1241
1241
///////////////////////////////////////////////////////////////////////////////
1242
1242
/**
1243
 
 *  
 
1243
 *
1244
1244
 *
1245
1245
 *  @author OLiver
1246
1246
 */
1247
1247
bool Window::Msg_LeftUp(const MouseCoords& mc)
1248
1248
{
1249
 
        return false;
 
1249
    return false;
1250
1250
}
1251
1251
 
1252
1252
bool Window::Msg_LeftDown_After(const MouseCoords& mc)
1253
1253
{
1254
 
        return false;
 
1254
    return false;
1255
1255
}
1256
1256
 
1257
1257
///////////////////////////////////////////////////////////////////////////////
1258
1258
/**
1259
 
 *  
 
1259
 *
1260
1260
 *
1261
1261
 *  @author OLiver
1262
1262
 */
1263
1263
bool Window::Msg_RightUp(const MouseCoords& mc)
1264
1264
{
1265
 
        return false;
 
1265
    return false;
1266
1266
}
1267
1267
 
1268
1268
///////////////////////////////////////////////////////////////////////////////
1273
1273
 */
1274
1274
bool Window::Msg_WheelUp(const MouseCoords& mc)
1275
1275
{
1276
 
        return false;
 
1276
    return false;
1277
1277
}
1278
1278
 
1279
1279
///////////////////////////////////////////////////////////////////////////////
1284
1284
 */
1285
1285
bool Window::Msg_WheelDown(const MouseCoords& mc)
1286
1286
{
1287
 
        return false;
 
1287
    return false;
1288
1288
}
1289
1289
 
1290
1290
///////////////////////////////////////////////////////////////////////////////
1291
1291
/**
1292
 
 *  
 
1292
 *
1293
1293
 *
1294
1294
 *  @author OLiver
1295
1295
 */
1296
1296
bool Window::Msg_MouseMove(const MouseCoords& mc)
1297
1297
{
1298
 
        return false;
 
1298
    return false;
1299
1299
}
1300
1300
 
1301
1301
///////////////////////////////////////////////////////////////////////////////
1302
1302
/**
1303
 
 *  
 
1303
 *
1304
1304
 *
1305
1305
 *  @author OLiver
1306
1306
 */
1307
1307
bool Window::Msg_KeyDown(const KeyEvent& ke)
1308
1308
{
1309
 
        return false;
 
1309
    return false;
1310
1310
}
1311
1311
 
1312
1312
///////////////////////////////////////////////////////////////////////////////
1313
1313
/**
1314
 
 *  
 
1314
 *
1315
1315
 *
1316
1316
 *  @author OLiver
1317
1317
 */
1321
1321
 
1322
1322
///////////////////////////////////////////////////////////////////////////////
1323
1323
/**
1324
 
 *  
 
1324
 *
1325
1325
 *
1326
1326
 *  @author Divan
1327
1327
 */
1332
1332
 
1333
1333
///////////////////////////////////////////////////////////////////////////////
1334
1334
/**
1335
 
 *  
 
1335
 *
1336
1336
 *
1337
1337
 *  @author OLiver
1338
1338
 */
1342
1342
 
1343
1343
///////////////////////////////////////////////////////////////////////////////
1344
1344
/**
1345
 
 *  
 
1345
 *
1346
1346
 *
1347
1347
 *  @author OLiver
1348
1348
 */
1352
1352
 
1353
1353
///////////////////////////////////////////////////////////////////////////////
1354
1354
/**
1355
 
 *  
 
1355
 *
1356
1356
 *
1357
1357
 *  @author OLiver
1358
1358
 */
1362
1362
 
1363
1363
///////////////////////////////////////////////////////////////////////////////
1364
1364
/**
1365
 
 *  
 
1365
 *
1366
1366
 *
1367
1367
 *  @author OLiver
1368
1368
 */
1376
1376
 
1377
1377
///////////////////////////////////////////////////////////////////////////////
1378
1378
/**
1379
 
 *  
 
1379
 *
1380
1380
 *
1381
1381
 *  @author OLiver
1382
1382
 */
1386
1386
 
1387
1387
///////////////////////////////////////////////////////////////////////////////
1388
1388
/**
1389
 
 *  
 
1389
 *
1390
1390
 *
1391
1391
 *  @author OLiver
1392
1392
 */
1396
1396
 
1397
1397
///////////////////////////////////////////////////////////////////////////////
1398
1398
/**
1399
 
 *  
 
1399
 *
1400
1400
 *
1401
1401
 *  @author OLiver
1402
1402
 */
1406
1406
 
1407
1407
///////////////////////////////////////////////////////////////////////////////
1408
1408
/**
1409
 
 *  
 
1409
 *
1410
1410
 *
1411
1411
 *  @author FloSoft
1412
1412
 */
1416
1416
 
1417
1417
///////////////////////////////////////////////////////////////////////////////
1418
1418
/**
1419
 
 *  
 
1419
 *
1420
1420
 *
1421
1421
 *  @author OLiver
1422
1422
 */
1426
1426
 
1427
1427
///////////////////////////////////////////////////////////////////////////////
1428
1428
/**
1429
 
 *  
 
1429
 *
1430
1430
 *
1431
1431
 *  @author OLiver
1432
1432
 */
1436
1436
 
1437
1437
///////////////////////////////////////////////////////////////////////////////
1438
1438
/**
1439
 
 *  
 
1439
 *
1440
1440
 *
1441
1441
 *  @author OLiver
1442
1442
 */
1446
1446
 
1447
1447
///////////////////////////////////////////////////////////////////////////////
1448
1448
/**
1449
 
 *  
 
1449
 *
1450
1450
 *
1451
1451
 *  @author OLiver
1452
1452
 */
1460
1460
 
1461
1461
///////////////////////////////////////////////////////////////////////////////
1462
1462
/**
1463
 
 *  
 
1463
 *
1464
1464
 *
1465
1465
 *  @author OLiver
1466
1466
 */
1470
1470
 
1471
1471
///////////////////////////////////////////////////////////////////////////////
1472
1472
/**
1473
 
 *  
 
1473
 *
1474
1474
 *
1475
1475
 *  @author OLiver
1476
1476
 */
1480
1480
 
1481
1481
///////////////////////////////////////////////////////////////////////////////
1482
1482
/**
1483
 
 *  
 
1483
 *
1484
1484
 *
1485
1485
 *  @author OLiver
1486
1486
 */
1487
 
void Window::Msg_MsgBoxResult(const unsigned msgbox_id, const MsgboxResult mbr) 
 
1487
void Window::Msg_MsgBoxResult(const unsigned msgbox_id, const MsgboxResult mbr)
1488
1488
{
1489
1489
}
1490
1490
 
1491
1491
///////////////////////////////////////////////////////////////////////////////
1492
1492
/**
1493
 
 *  
 
1493
 *
1494
1494
 *
1495
1495
 *  @author OLiver
1496
1496
 */
1500
1500
 
1501
1501
///////////////////////////////////////////////////////////////////////////////
1502
1502
/**
1503
 
 *  
 
1503
 *
1504
1504
 *
1505
1505
 *  @author OLiver
1506
1506
 */
1510
1510
 
1511
1511
///////////////////////////////////////////////////////////////////////////////
1512
1512
/**
1513
 
 *  
 
1513
 *
1514
1514
 *
1515
1515
 *  @author OLiver
1516
1516
 */
1520
1520
 
1521
1521
///////////////////////////////////////////////////////////////////////////////
1522
1522
/**
1523
 
 *  
 
1523
 *
1524
1524
 *
1525
1525
 *  @author OLiver
1526
1526
 */
1530
1530
 
1531
1531
///////////////////////////////////////////////////////////////////////////////
1532
1532
/**
1533
 
 *  
 
1533
 *
1534
1534
 *
1535
1535
 *  @author OLiver
1536
1536
 */
1540
1540
 
1541
1541
///////////////////////////////////////////////////////////////////////////////
1542
1542
/**
1543
 
 *  
 
1543
 *
1544
1544
 *
1545
1545
 *  @author OLiver
1546
1546
 */
1550
1550
 
1551
1551
///////////////////////////////////////////////////////////////////////////////
1552
1552
/**
1553
 
 *  
 
1553
 *
1554
1554
 *
1555
1555
 *  @author OLiver
1556
1556
 */
1560
1560
 
1561
1561
///////////////////////////////////////////////////////////////////////////////
1562
1562
/**
1563
 
 *  
 
1563
 *
1564
1564
 *
1565
1565
 *  @author OLiver
1566
1566
 */
1570
1570
 
1571
1571
///////////////////////////////////////////////////////////////////////////////
1572
1572
/**
1573
 
 *  
 
1573
 *
1574
1574
 *
1575
1575
 *  @author OLiver
1576
1576
 */
1580
1580
 
1581
1581
///////////////////////////////////////////////////////////////////////////////
1582
1582
/**
1583
 
 *  
 
1583
 *
1584
1584
 *
1585
1585
 *  @author OLiver
1586
1586
 */
1590
1590
 
1591
1591
///////////////////////////////////////////////////////////////////////////////
1592
1592
/**
1593
 
 *  
 
1593
 *
1594
1594
 *
1595
1595
 *  @author OLiver
1596
1596
 */
1600
1600
 
1601
1601
///////////////////////////////////////////////////////////////////////////////
1602
1602
/**
1603
 
 *  
 
1603
 *
1604
1604
 *
1605
1605
 *  @author OLiver
1606
1606
 */
1610
1610
 
1611
1611
///////////////////////////////////////////////////////////////////////////////
1612
1612
/**
1613
 
 *  
 
1613
 *
1614
1614
 *
1615
1615
 *  @author OLiver
1616
1616
 */
1620
1620
 
1621
1621
///////////////////////////////////////////////////////////////////////////////
1622
1622
/**
1623
 
 *  
 
1623
 *
1624
1624
 *
1625
1625
 *  @author OLiver
1626
1626
 */