|
|
|
@ -121,7 +121,13 @@ void MainWindow::get_builder(){
|
|
|
|
builder->get_widget("iconDevelopment", iconDevelopment);
|
|
|
|
builder->get_widget("iconDevelopment", iconDevelopment);
|
|
|
|
builder->get_widget("iconSystem", iconSystem);
|
|
|
|
builder->get_widget("iconSystem", iconSystem);
|
|
|
|
builder->get_widget("lblSystem", lblSystem);
|
|
|
|
builder->get_widget("lblSystem", lblSystem);
|
|
|
|
Gtk::IconView *array_icon[10];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void MainWindow::set_icon_array(){
|
|
|
|
array_icon[0]=this->iconGraphics;
|
|
|
|
array_icon[0]=this->iconGraphics;
|
|
|
|
array_icon[1]=this->iconTools;
|
|
|
|
array_icon[1]=this->iconTools;
|
|
|
|
array_icon[2]=this->iconInternet;
|
|
|
|
array_icon[2]=this->iconInternet;
|
|
|
|
@ -132,12 +138,9 @@ void MainWindow::get_builder(){
|
|
|
|
array_icon[7]=this->iconOther;
|
|
|
|
array_icon[7]=this->iconOther;
|
|
|
|
array_icon[8]=this->iconDevelopment;
|
|
|
|
array_icon[8]=this->iconDevelopment;
|
|
|
|
array_icon[9]=this->iconSystem;
|
|
|
|
array_icon[9]=this->iconSystem;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void MainWindow::template_apps_obj(Gtk::IconView *icon, Glib::RefPtr<Gtk::ListStore> >k_list_app){
|
|
|
|
void MainWindow::template_apps_obj(Gtk::IconView *icon, Glib::RefPtr<Gtk::ListStore> >k_list_app){
|
|
|
|
gtk_list_app = Gtk::ListStore::create(m_Columns);
|
|
|
|
gtk_list_app = Gtk::ListStore::create(m_Columns);
|
|
|
|
gtk_list_app->set_sort_column(m_Columns.m_col_description, Gtk::SORT_ASCENDING);
|
|
|
|
gtk_list_app->set_sort_column(m_Columns.m_col_description, Gtk::SORT_ASCENDING);
|
|
|
|
@ -268,9 +271,12 @@ void MainWindow::select_System(){
|
|
|
|
this->tempate_icon_select(this->iconSystem,list_System);
|
|
|
|
this->tempate_icon_select(this->iconSystem,list_System);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
void MainWindow::tempate_icon_select(Gtk::IconView *icon, Glib::RefPtr<Gtk::ListStore> >k_list){
|
|
|
|
void MainWindow::tempate_icon_select(Gtk::IconView *icon, Glib::RefPtr<Gtk::ListStore> >k_list){
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
auto selected = (*icon).get_selected_items();
|
|
|
|
auto selected = (*icon).get_selected_items();
|
|
|
|
if(!selected.empty())
|
|
|
|
if(!selected.empty())
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
this->set_icon_array();
|
|
|
|
this->unselect_icon(icon);
|
|
|
|
this->unselect_icon(icon);
|
|
|
|
const Gtk::TreeModel::Path& path = *selected.begin();
|
|
|
|
const Gtk::TreeModel::Path& path = *selected.begin();
|
|
|
|
Gtk::TreeModel::iterator iter = gtk_list->get_iter(path);
|
|
|
|
Gtk::TreeModel::iterator iter = gtk_list->get_iter(path);
|
|
|
|
@ -294,10 +300,9 @@ void MainWindow::tempate_icon_select(Gtk::IconView *icon, Glib::RefPtr<Gtk::List
|
|
|
|
void MainWindow::unselect_icon(Gtk::IconView *icon_entry){
|
|
|
|
void MainWindow::unselect_icon(Gtk::IconView *icon_entry){
|
|
|
|
for (int index=0; index<10; ++index){
|
|
|
|
for (int index=0; index<10; ++index){
|
|
|
|
Gtk::IconView *icon = this->array_icon[index];
|
|
|
|
Gtk::IconView *icon = this->array_icon[index];
|
|
|
|
printf("%p %p", icon, icon_entry);
|
|
|
|
if (icon_entry!=icon){
|
|
|
|
if (&icon_entry!=&icon){
|
|
|
|
|
|
|
|
cout << "11111" << endl;
|
|
|
|
cout << "11111" << endl;
|
|
|
|
//icon->unselect_all();
|
|
|
|
icon->unselect_all();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else{
|
|
|
|
else{
|
|
|
|
cout << "22222" << endl;
|
|
|
|
cout << "22222" << endl;
|
|
|
|
|