2024-08-10 17:57:15 +03:00
|
|
|
#include "header.hpp"
|
2024-08-20 14:38:13 +03:00
|
|
|
#include "header/main.hpp"
|
2024-08-10 17:57:15 +03:00
|
|
|
#include "header/menu.hpp"
|
|
|
|
#include "header/tab.hpp"
|
|
|
|
|
|
|
|
using namespace app::browser;
|
|
|
|
|
|
|
|
Header::Header()
|
|
|
|
{
|
2024-08-12 09:45:22 +03:00
|
|
|
// Init header bar
|
2024-08-10 17:57:15 +03:00
|
|
|
set_show_title_buttons(
|
2024-08-27 16:27:56 +03:00
|
|
|
SHOW_TITLE_BUTTONS
|
2024-08-10 17:57:15 +03:00
|
|
|
);
|
|
|
|
|
2024-08-12 09:45:22 +03:00
|
|
|
// Init menu
|
2024-08-27 16:27:56 +03:00
|
|
|
headerMenu = new header::Menu();
|
2024-08-12 09:45:22 +03:00
|
|
|
|
2024-08-10 17:57:15 +03:00
|
|
|
pack_start(
|
2024-08-27 16:27:56 +03:00
|
|
|
* headerMenu
|
2024-08-10 17:57:15 +03:00
|
|
|
);
|
|
|
|
|
2024-08-12 09:45:22 +03:00
|
|
|
// Init tab
|
2024-08-27 16:27:56 +03:00
|
|
|
headerTab = new header::Tab();
|
2024-08-12 09:45:22 +03:00
|
|
|
|
2024-08-10 17:57:15 +03:00
|
|
|
pack_start(
|
2024-08-27 16:27:56 +03:00
|
|
|
* headerTab
|
2024-08-12 09:45:22 +03:00
|
|
|
);
|
2024-08-20 14:38:13 +03:00
|
|
|
|
|
|
|
// Init main widget
|
2024-08-27 16:27:56 +03:00
|
|
|
headerMain = new header::Main();
|
2024-08-20 14:38:13 +03:00
|
|
|
|
|
|
|
set_title_widget(
|
2024-08-27 16:27:56 +03:00
|
|
|
* headerMain
|
2024-08-20 14:38:13 +03:00
|
|
|
);
|
2024-08-12 09:45:22 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
Header::~Header()
|
|
|
|
{
|
2024-08-27 16:27:56 +03:00
|
|
|
delete headerMain;
|
|
|
|
delete headerMenu;
|
|
|
|
delete headerTab;
|
2024-08-20 15:25:31 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
void Header::set_title(
|
2024-08-27 16:27:56 +03:00
|
|
|
const Glib::ustring & VALUE
|
2024-08-20 15:25:31 +03:00
|
|
|
) {
|
2024-08-27 16:27:56 +03:00
|
|
|
headerMain->set_title(
|
|
|
|
VALUE
|
2024-08-20 15:25:31 +03:00
|
|
|
);
|
2024-08-27 16:22:48 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
void Header::set_subtitle(
|
2024-08-27 16:27:56 +03:00
|
|
|
const Glib::ustring & VALUE
|
2024-08-27 16:22:48 +03:00
|
|
|
) {
|
2024-08-27 16:27:56 +03:00
|
|
|
headerMain->set_subtitle(
|
|
|
|
VALUE
|
2024-08-27 16:22:48 +03:00
|
|
|
);
|
2024-08-10 17:57:15 +03:00
|
|
|
}
|