2024-08-12 21:35:52 +03:00
|
|
|
#ifndef APP_BROWSER_MAIN_HPP
|
|
|
|
#define APP_BROWSER_MAIN_HPP
|
2024-08-11 22:04:34 +03:00
|
|
|
|
2024-08-27 14:15:13 +03:00
|
|
|
#include <glibmm/i18n.h>
|
2024-08-20 16:27:35 +03:00
|
|
|
#include <glibmm/ustring.h>
|
2024-08-11 22:04:34 +03:00
|
|
|
#include <gtkmm/box.h>
|
2024-09-02 16:25:31 +03:00
|
|
|
#include <gtkmm/object.h>
|
2024-08-11 22:04:34 +03:00
|
|
|
|
|
|
|
namespace app::browser
|
|
|
|
{
|
|
|
|
namespace main
|
|
|
|
{
|
|
|
|
class Tab;
|
|
|
|
}
|
|
|
|
|
|
|
|
class Main : public Gtk::Box
|
|
|
|
{
|
2024-08-27 16:00:12 +03:00
|
|
|
// Components
|
2024-08-27 14:30:23 +03:00
|
|
|
main::Tab * mainTab;
|
2024-08-11 22:04:34 +03:00
|
|
|
|
2024-08-27 16:00:12 +03:00
|
|
|
// Defaults
|
|
|
|
const bool HOMOGENEOUS = true;
|
|
|
|
|
2024-08-11 22:04:34 +03:00
|
|
|
public:
|
|
|
|
|
|
|
|
Main();
|
2024-08-12 09:45:22 +03:00
|
|
|
|
2024-08-27 16:00:12 +03:00
|
|
|
// Getters
|
2024-08-27 16:39:44 +03:00
|
|
|
Glib::ustring get_current_tab_page_title();
|
|
|
|
Glib::ustring get_current_tab_page_subtitle();
|
2024-08-20 16:27:35 +03:00
|
|
|
|
2024-08-27 16:00:12 +03:00
|
|
|
// Actions
|
2024-09-05 16:48:28 +03:00
|
|
|
void refresh();
|
2024-09-05 02:50:41 +03:00
|
|
|
|
2024-09-05 16:48:28 +03:00
|
|
|
void tab_append();
|
|
|
|
void tab_close_all();
|
|
|
|
void tab_close_left();
|
|
|
|
void tab_close_right();
|
|
|
|
void tab_close();
|
|
|
|
|
|
|
|
void tab_page_navigation_update();
|
|
|
|
bool tab_page_navigation_history_try_back();
|
|
|
|
bool tab_page_navigation_history_try_forward();
|
2024-08-27 15:53:15 +03:00
|
|
|
|
2024-09-05 02:50:41 +03:00
|
|
|
|
2024-08-11 22:04:34 +03:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|
2024-08-12 21:35:52 +03:00
|
|
|
#endif // APP_BROWSER_MAIN_HPP
|