2008-01-18 22:49:52 -05:00
|
|
|
/*
|
2019-08-02 17:26:43 -04:00
|
|
|
* Copyright (C) 2008-2009 David Robillard <d@drobilla.net>
|
|
|
|
* Copyright (C) 2009-2013 Paul Davis <paul@linuxaudiosystems.com>
|
|
|
|
* Copyright (C) 2017 Robin Gareus <robin@gareus.org>
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License along
|
|
|
|
* with this program; if not, write to the Free Software Foundation, Inc.,
|
|
|
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
|
|
*/
|
2008-01-18 22:49:52 -05:00
|
|
|
|
|
|
|
#ifndef __ardour_gtk_splash_h__
|
|
|
|
#define __ardour_gtk_splash_h__
|
|
|
|
|
2021-06-23 06:52:16 -04:00
|
|
|
#include <set>
|
|
|
|
|
2008-01-18 22:49:52 -05:00
|
|
|
#include <gtkmm/window.h>
|
2008-01-19 00:06:33 -05:00
|
|
|
#include <gtkmm/drawingarea.h>
|
|
|
|
#include <gtkmm/box.h>
|
|
|
|
#include <gtkmm/label.h>
|
2008-01-18 22:49:52 -05:00
|
|
|
#include <gdkmm/pixbuf.h>
|
|
|
|
|
2009-12-19 15:26:31 -05:00
|
|
|
#include "pbd/signals.h"
|
|
|
|
|
2008-01-18 22:49:52 -05:00
|
|
|
class ARDOUR_UI;
|
|
|
|
|
|
|
|
class Splash : public Gtk::Window
|
|
|
|
{
|
2017-05-11 07:44:17 -04:00
|
|
|
public:
|
2012-06-01 15:49:40 -04:00
|
|
|
~Splash ();
|
2008-01-18 22:49:52 -05:00
|
|
|
|
2019-10-11 16:29:55 -04:00
|
|
|
static Splash* instance();
|
|
|
|
static void drop();
|
|
|
|
static bool exists ();
|
2008-02-02 12:22:04 -05:00
|
|
|
|
2017-05-11 07:44:17 -04:00
|
|
|
void display ();
|
2012-01-10 13:21:39 -05:00
|
|
|
void pop_back_for (Gtk::Window&);
|
2021-06-23 06:52:16 -04:00
|
|
|
void pop_front_for (Gtk::Window&);
|
2008-02-02 12:22:04 -05:00
|
|
|
|
2008-01-19 00:06:33 -05:00
|
|
|
bool expose (GdkEventExpose*);
|
2008-01-18 22:49:52 -05:00
|
|
|
bool on_button_release_event (GdkEventButton*);
|
2008-01-19 00:06:33 -05:00
|
|
|
void on_realize ();
|
2017-05-11 07:44:17 -04:00
|
|
|
bool on_map_event (GdkEventAny*);
|
2008-01-19 00:06:33 -05:00
|
|
|
void message (const std::string& msg);
|
2017-05-11 08:20:33 -04:00
|
|
|
void hide ();
|
2009-10-14 12:10:01 -04:00
|
|
|
|
2017-05-11 07:44:17 -04:00
|
|
|
private:
|
2019-10-11 16:29:55 -04:00
|
|
|
Splash ();
|
2008-02-02 12:22:04 -05:00
|
|
|
static Splash* the_splash;
|
|
|
|
|
2008-01-18 22:49:52 -05:00
|
|
|
Glib::RefPtr<Gdk::Pixbuf> pixbuf;
|
2008-01-19 00:06:33 -05:00
|
|
|
Gtk::DrawingArea darea;
|
|
|
|
Glib::RefPtr<Pango::Layout> layout;
|
2008-02-16 17:43:18 -05:00
|
|
|
|
2021-06-23 06:52:16 -04:00
|
|
|
void pop_front ();
|
|
|
|
std::set<Gtk::Window*> _window_stack;
|
|
|
|
|
2008-02-16 17:43:18 -05:00
|
|
|
void boot_message (std::string);
|
2009-12-19 15:26:31 -05:00
|
|
|
PBD::ScopedConnection msg_connection;
|
2012-07-09 17:54:21 -04:00
|
|
|
|
2017-05-11 08:20:33 -04:00
|
|
|
sigc::connection idle_connection;
|
|
|
|
volatile bool expose_done;
|
2017-05-11 07:44:17 -04:00
|
|
|
bool expose_is_the_one;
|
|
|
|
bool idle_after_expose ();
|
2009-10-14 12:10:01 -04:00
|
|
|
};
|
2008-01-18 22:49:52 -05:00
|
|
|
|
|
|
|
#endif /* __ardour_gtk_splash_h__ */
|