~ubuntu-branches/ubuntu/wily/bombono-dvd/wily

« back to all changes in this revision

Viewing changes to src/mgui/sdk/window.h

  • Committer: Bazaar Package Importer
  • Author(s): Alessio Treglia
  • Date: 2010-11-04 11:46:25 UTC
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: james.westby@ubuntu.com-20101104114625-8xfdhvhpsm51i0nu
Tags: upstream-0.8.0
ImportĀ upstreamĀ versionĀ 0.8.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
2
2
// mgui/sdk/window.h
3
3
// This file is part of Bombono DVD project.
4
4
//
5
 
// Copyright (c) 2009 Ilya Murav'jov
 
5
// Copyright (c) 2009-2010 Ilya Murav'jov
6
6
//
7
7
// This program is free software; you can redistribute it and/or modify
8
8
// it under the terms of the GNU General Public License as published by
22
22
#ifndef __MGUI_SDK_WINDOW_H__
23
23
#define __MGUI_SDK_WINDOW_H__
24
24
 
25
 
inline void RunWindow(Gtk::Window& win)
26
 
{
27
 
    win.show_all();
28
 
    Gtk::Main::run(win);
29
 
}
30
 
 
31
 
inline Gtk::Window* GetTopWindow(Gtk::Widget& wdg)
32
 
{
33
 
    return dynamic_cast<Gtk::Window*>(wdg.get_toplevel());
34
 
}
35
 
 
36
 
inline void SetAppWindowSize(Gtk::Window& win, int wdh)
37
 
{
38
 
    win.set_default_size(wdh, wdh*3/5);
39
 
}
 
25
#include <mlib/geom2d.h>
 
26
 
 
27
void RunWindow(Gtk::Window& win);
 
28
 
 
29
Gtk::Window* GetTopWindow(Gtk::Widget& wdg);
 
30
 
 
31
Point CalcBeautifulRect(int wdh);
 
32
 
 
33
void SetAppWindowSize(Gtk::Window& win, int wdh);
40
34
 
41
35
#endif // __MGUI_SDK_WINDOW_H__
42
36