mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-04-02 09:35:28 +00:00
init tab data container
This commit is contained in:
parent
d9b4983d4f
commit
3918ab9993
6 changed files with 41 additions and 3 deletions
1
Makefile
1
Makefile
|
|
@ -12,6 +12,7 @@ SRCS = src/main.cpp\
|
||||||
src/app/browser/header/tab.cpp\
|
src/app/browser/header/tab.cpp\
|
||||||
src/app/browser/main.cpp\
|
src/app/browser/main.cpp\
|
||||||
src/app/browser/main/tab.cpp\
|
src/app/browser/main/tab.cpp\
|
||||||
|
src/app/browser/main/tab/data.cpp\
|
||||||
src/app/browser/main/tab/label.cpp\
|
src/app/browser/main/tab/label.cpp\
|
||||||
src/lib/database.cpp\
|
src/lib/database.cpp\
|
||||||
src/lib/database/session.cpp
|
src/lib/database/session.cpp
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ src/app/browser/header/menu.cpp
|
||||||
src/app/browser/header/tab.cpp
|
src/app/browser/header/tab.cpp
|
||||||
src/app/browser/main.cpp
|
src/app/browser/main.cpp
|
||||||
src/app/browser/main/tab.cpp
|
src/app/browser/main/tab.cpp
|
||||||
|
src/app/browser/main/tab/data.cpp
|
||||||
src/app/browser/main/tab/label.cpp
|
src/app/browser/main/tab/label.cpp
|
||||||
src/lib/database.cpp
|
src/lib/database.cpp
|
||||||
src/lib/database/session.cpp
|
src/lib/database/session.cpp
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
#include "tab.hpp"
|
#include "tab.hpp"
|
||||||
|
#include "tab/data.hpp"
|
||||||
#include "tab/label.hpp"
|
#include "tab/label.hpp"
|
||||||
|
|
||||||
using namespace app::browser::main;
|
using namespace app::browser::main;
|
||||||
|
|
@ -17,11 +18,9 @@ void Tab::append(
|
||||||
bool open,
|
bool open,
|
||||||
bool focus
|
bool focus
|
||||||
) {
|
) {
|
||||||
// Init new tab label
|
|
||||||
label = new tab::Label();
|
label = new tab::Label();
|
||||||
|
|
||||||
// Init tab data container @TODO
|
data = new tab::Data();
|
||||||
Gtk::Label * data = new Gtk::Label("data");
|
|
||||||
|
|
||||||
append_page(
|
append_page(
|
||||||
* data,
|
* data,
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,7 @@ namespace app::browser::main
|
||||||
{
|
{
|
||||||
namespace tab
|
namespace tab
|
||||||
{
|
{
|
||||||
|
class Data;
|
||||||
class Label;
|
class Label;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -15,6 +16,7 @@ namespace app::browser::main
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
tab::Data * data;
|
||||||
tab::Label * label;
|
tab::Label * label;
|
||||||
|
|
||||||
Tab();
|
Tab();
|
||||||
|
|
|
||||||
16
src/app/browser/main/tab/data.cpp
Normal file
16
src/app/browser/main/tab/data.cpp
Normal file
|
|
@ -0,0 +1,16 @@
|
||||||
|
#include "data.hpp"
|
||||||
|
|
||||||
|
using namespace app::browser::main::tab;
|
||||||
|
|
||||||
|
Data::Data()
|
||||||
|
{
|
||||||
|
set_orientation(
|
||||||
|
Gtk::Orientation::VERTICAL
|
||||||
|
);
|
||||||
|
|
||||||
|
set_homogeneous(
|
||||||
|
true
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
Data::~Data() = default;
|
||||||
19
src/app/browser/main/tab/data.hpp
Normal file
19
src/app/browser/main/tab/data.hpp
Normal file
|
|
@ -0,0 +1,19 @@
|
||||||
|
#ifndef APP_BROWSER_MAIN_TAB_DATA_HPP
|
||||||
|
#define APP_BROWSER_MAIN_TAB_DATA_HPP
|
||||||
|
|
||||||
|
#include <glibmm/i18n.h>
|
||||||
|
#include <gtkmm/box.h>
|
||||||
|
|
||||||
|
namespace app::browser::main::tab
|
||||||
|
{
|
||||||
|
class Data : public Gtk::Box
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
|
||||||
|
Data();
|
||||||
|
|
||||||
|
~Data();
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif // APP_BROWSER_MAIN_TAB_DATA_HPP
|
||||||
Loading…
Add table
Add a link
Reference in a new issue