Replaced treestore with liststore. I decided i didn't need a treeview
* include/Dialog_Filesystems.h, src/Dialog_Filesystems.cc: Replaced treestore with liststore. I decided i didn't need a treeview after all... * src/Dialog_About.cc: Replaced "Gnome Partition Editor based on libparted" with "Gnome Partition Editor" * src/xfs.cc: fixed small error with creation of xfs filesystems (adrighem)
This commit is contained in:
parent
589d18befb
commit
8d412f95bd
|
@ -1,3 +1,10 @@
|
||||||
|
2004-12-18 Bart Hakvoort <gparted@users.sf.net>
|
||||||
|
|
||||||
|
* include/Dialog_Filesystems.h,
|
||||||
|
src/Dialog_Filesystems.cc: Replaced treestore with liststore. I decided i didn't need a treeview after all...
|
||||||
|
* src/Dialog_About.cc: Replaced "Gnome Partition Editor based on libparted" with "Gnome Partition Editor"
|
||||||
|
* src/xfs.cc: fixed small error with creation of xfs filesystems (adrighem)
|
||||||
|
|
||||||
2004-12-17 Bart Hakvoort <gparted@users.sf.net>
|
2004-12-17 Bart Hakvoort <gparted@users.sf.net>
|
||||||
|
|
||||||
* include/GParted_Core.h,
|
* include/GParted_Core.h,
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
#include <gtkmm/dialog.h>
|
#include <gtkmm/dialog.h>
|
||||||
#include <gtkmm/stock.h>
|
#include <gtkmm/stock.h>
|
||||||
#include <gtkmm/treeview.h>
|
#include <gtkmm/treeview.h>
|
||||||
#include <gtkmm/treestore.h>
|
#include <gtkmm/liststore.h>
|
||||||
|
|
||||||
namespace GParted
|
namespace GParted
|
||||||
{
|
{
|
||||||
|
@ -42,7 +42,7 @@ private:
|
||||||
|
|
||||||
Gtk::TreeView treeview_filesystems;
|
Gtk::TreeView treeview_filesystems;
|
||||||
Gtk::TreeRow treerow;
|
Gtk::TreeRow treerow;
|
||||||
Glib::RefPtr<Gtk::TreeStore> treestore_filesystems;
|
Glib::RefPtr<Gtk::ListStore> liststore_filesystems;
|
||||||
|
|
||||||
struct treeview_filesystems_Columns : public Gtk::TreeModelColumnRecord
|
struct treeview_filesystems_Columns : public Gtk::TreeModelColumnRecord
|
||||||
{
|
{
|
||||||
|
|
|
@ -24,13 +24,13 @@ Dialog_About::Dialog_About()
|
||||||
{
|
{
|
||||||
/*TO TRANSLATORS: this is the dialog title */
|
/*TO TRANSLATORS: this is the dialog title */
|
||||||
this ->set_title( _( "About GParted" ) );
|
this ->set_title( _( "About GParted" ) );
|
||||||
this ->set_size_request( -1, 220 ) ;
|
this ->set_size_request( 250, 220 ) ;
|
||||||
this ->set_resizable( false );
|
this ->set_resizable( false );
|
||||||
this ->set_has_separator( false ) ;
|
this ->set_has_separator( false ) ;
|
||||||
|
|
||||||
this ->get_vbox() ->pack_start( * mk_label( "\n<span size='small'>logo here ;)</span>\n", true, false ), Gtk::PACK_SHRINK );
|
this ->get_vbox() ->pack_start( * mk_label( "\n<span size='small'>logo here ;)</span>\n", true, false ), Gtk::PACK_SHRINK );
|
||||||
this ->get_vbox() ->pack_start( * mk_label( "<span size='xx-large'><b>" + (Glib::ustring) _( "GParted" ) + " " + VERSION + "</b></span>", true, false ) ,Gtk::PACK_SHRINK );
|
this ->get_vbox() ->pack_start( * mk_label( "<span size='xx-large'><b>" + (Glib::ustring) _( "GParted" ) + " " + VERSION + "</b></span>", true, false ) ,Gtk::PACK_SHRINK );
|
||||||
this ->get_vbox() ->pack_start( * mk_label( "\n" + (Glib::ustring) _( "Gnome Partition Editor based on libparted" ) + "\n", false, false ) ,Gtk::PACK_SHRINK );
|
this ->get_vbox() ->pack_start( * mk_label( "\n" + (Glib::ustring) _( "Gnome Partition Editor" ) + "\n", false, false ) ,Gtk::PACK_SHRINK );
|
||||||
this ->get_vbox() ->pack_start( * mk_label( "<span size='small'>Copyright © 2004 Bart Hakvoort</span>", true, false ), Gtk::PACK_SHRINK );
|
this ->get_vbox() ->pack_start( * mk_label( "<span size='small'>Copyright © 2004 Bart Hakvoort</span>", true, false ), Gtk::PACK_SHRINK );
|
||||||
this ->get_vbox() ->pack_start( * mk_label( "<span size='small'>http://gparted.sourceforge.net</span>", true, false ), Gtk::PACK_SHRINK );
|
this ->get_vbox() ->pack_start( * mk_label( "<span size='small'>http://gparted.sourceforge.net</span>", true, false ), Gtk::PACK_SHRINK );
|
||||||
|
|
||||||
|
|
|
@ -26,8 +26,8 @@ Dialog_Filesystems::Dialog_Filesystems( )
|
||||||
this ->set_has_separator( false ) ;
|
this ->set_has_separator( false ) ;
|
||||||
this ->set_resizable( false ) ;
|
this ->set_resizable( false ) ;
|
||||||
|
|
||||||
treestore_filesystems = Gtk::TreeStore::create( treeview_filesystems_columns );
|
liststore_filesystems = Gtk::ListStore::create( treeview_filesystems_columns );
|
||||||
treeview_filesystems .set_model( treestore_filesystems );
|
treeview_filesystems .set_model( liststore_filesystems );
|
||||||
treeview_filesystems .append_column( _("Filesystem"), treeview_filesystems_columns .filesystem );
|
treeview_filesystems .append_column( _("Filesystem"), treeview_filesystems_columns .filesystem );
|
||||||
treeview_filesystems .append_column( _("Create"), treeview_filesystems_columns .create );
|
treeview_filesystems .append_column( _("Create"), treeview_filesystems_columns .create );
|
||||||
treeview_filesystems .append_column( _("Grow"), treeview_filesystems_columns .grow );
|
treeview_filesystems .append_column( _("Grow"), treeview_filesystems_columns .grow );
|
||||||
|
@ -35,6 +35,7 @@ Dialog_Filesystems::Dialog_Filesystems( )
|
||||||
treeview_filesystems .append_column( _("Move"), treeview_filesystems_columns .move );
|
treeview_filesystems .append_column( _("Move"), treeview_filesystems_columns .move );
|
||||||
treeview_filesystems .append_column( _("Copy"), treeview_filesystems_columns .copy );
|
treeview_filesystems .append_column( _("Copy"), treeview_filesystems_columns .copy );
|
||||||
|
|
||||||
|
treeview_filesystems .get_selection( ) ->set_mode( Gtk::SELECTION_NONE );
|
||||||
this ->get_vbox( ) ->pack_start( treeview_filesystems ) ;
|
this ->get_vbox( ) ->pack_start( treeview_filesystems ) ;
|
||||||
|
|
||||||
this ->add_button( Gtk::Stock::REFRESH, Gtk::RESPONSE_OK );
|
this ->add_button( Gtk::Stock::REFRESH, Gtk::RESPONSE_OK );
|
||||||
|
@ -44,7 +45,7 @@ Dialog_Filesystems::Dialog_Filesystems( )
|
||||||
|
|
||||||
void Dialog_Filesystems::Load_Filesystems( const std::vector< FS > & FILESYSTEMS )
|
void Dialog_Filesystems::Load_Filesystems( const std::vector< FS > & FILESYSTEMS )
|
||||||
{
|
{
|
||||||
treestore_filesystems ->clear( ) ;
|
liststore_filesystems ->clear( ) ;
|
||||||
|
|
||||||
for ( unsigned short t = 0; t < FILESYSTEMS .size( ) -1 ; t++ )
|
for ( unsigned short t = 0; t < FILESYSTEMS .size( ) -1 ; t++ )
|
||||||
Show_Filesystem( FILESYSTEMS[ t ] ) ;
|
Show_Filesystem( FILESYSTEMS[ t ] ) ;
|
||||||
|
@ -52,7 +53,7 @@ void Dialog_Filesystems::Load_Filesystems( const std::vector< FS > & FILESYSTEMS
|
||||||
|
|
||||||
void Dialog_Filesystems::Show_Filesystem( const FS & fs )
|
void Dialog_Filesystems::Show_Filesystem( const FS & fs )
|
||||||
{
|
{
|
||||||
treerow = *( treestore_filesystems ->append( ) );
|
treerow = *( liststore_filesystems ->append( ) );
|
||||||
treerow[ treeview_filesystems_columns .filesystem ] = fs .filesystem ;
|
treerow[ treeview_filesystems_columns .filesystem ] = fs .filesystem ;
|
||||||
treerow[ treeview_filesystems_columns .create ] = render_icon( fs .create ? Gtk::Stock::APPLY : Gtk::Stock::CANCEL, Gtk::ICON_SIZE_MENU );
|
treerow[ treeview_filesystems_columns .create ] = render_icon( fs .create ? Gtk::Stock::APPLY : Gtk::Stock::CANCEL, Gtk::ICON_SIZE_MENU );
|
||||||
treerow[ treeview_filesystems_columns .grow ] = render_icon( fs .grow ? Gtk::Stock::APPLY : Gtk::Stock::CANCEL, Gtk::ICON_SIZE_MENU );
|
treerow[ treeview_filesystems_columns .grow ] = render_icon( fs .grow ? Gtk::Stock::APPLY : Gtk::Stock::CANCEL, Gtk::ICON_SIZE_MENU );
|
||||||
|
|
|
@ -90,7 +90,7 @@ void xfs::Set_Used_Sectors( Partition & partition )
|
||||||
|
|
||||||
bool xfs::Create( const Glib::ustring device_path, const Partition & new_partition )
|
bool xfs::Create( const Glib::ustring device_path, const Partition & new_partition )
|
||||||
{
|
{
|
||||||
return ! Execute_Command( "mkfs.xfs " + new_partition .partition ) ;
|
return ! Execute_Command( "mkfs.xfs -f " + new_partition .partition ) ;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool xfs::Resize( const Partition & partition_new, bool fill_partition )
|
bool xfs::Resize( const Partition & partition_new, bool fill_partition )
|
||||||
|
|
Loading…
Reference in New Issue