68 lines
1.1 KiB
C++
68 lines
1.1 KiB
C++
/*
|
|
* Copyright 2014 (c) Anna Schumaker.
|
|
*/
|
|
#ifndef OCARINA_TABS_H
|
|
#define OCARINA_TABS_H
|
|
|
|
#include <gui/ocarina.h>
|
|
#include <gui/queue/label.h>
|
|
#include <gui/queue/window.h>
|
|
#include <core/playlist.h>
|
|
#include <core/queue.h>
|
|
|
|
class Tab {
|
|
private:
|
|
unsigned int tab_sorting_count;
|
|
std::string tab_sorting_title;
|
|
|
|
protected:
|
|
Glib::RefPtr<Gtk::Builder> tab_builder;
|
|
queue *tab_pq;
|
|
Gtk::VBox tab_vbox;
|
|
|
|
QueueLabel *tab_label;
|
|
|
|
/**
|
|
* Class helper functions
|
|
*/
|
|
void tab_unmap();
|
|
|
|
public:
|
|
QueueWindow *tab_window;
|
|
Tab(queue *);
|
|
virtual ~Tab();
|
|
|
|
/**
|
|
* QNotifier implementation
|
|
*/
|
|
void on_track_added(unsigned int);
|
|
virtual void on_track_removed(unsigned int);
|
|
void on_tracks_cleared(unsigned int);
|
|
void on_track_updated(unsigned int);
|
|
|
|
/**
|
|
* More helper functions
|
|
*/
|
|
int tab_page_num();
|
|
bool tab_is_cur();
|
|
void tab_runtime_changed();
|
|
void tab_focus_search();
|
|
|
|
/**
|
|
* GTK-MM callback functions
|
|
*/
|
|
void on_column_clicked(unsigned int);
|
|
};
|
|
|
|
|
|
Tab *find_tab(queue *);
|
|
void tab_focus_search();
|
|
void init_tabs();
|
|
void post_init_tabs();
|
|
void cleanup_tabs();
|
|
|
|
|
|
void init_queue_tabs();
|
|
|
|
#endif /* OCARINA_TABS_H */
|