diff --git a/ChangeLog b/ChangeLog index 6d79f84e..7bcafd61 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2004-11-17 Bart Hakvoort + + * src/ext3.cc: availability of 'tune2fs' command wasn't detected correctly. fixed + * src/fat32.cc: make use of dosfs tools (mkdosfs -F32) instead of libparted's Fat-creator. + 2004-11-17 Bart Hakvoort * Rewrote a large part of gparteds internal code. Filesystemssupport is now much more separated from the rest of gparted and diff --git a/include/FileSystem.h b/include/FileSystem.h index 069fd711..99077e12 100644 --- a/include/FileSystem.h +++ b/include/FileSystem.h @@ -93,7 +93,7 @@ protected: PedDevice *device ; PedDisk *disk ; - + private: void Update_Textview( ) ; diff --git a/po/ChangeLog b/po/ChangeLog index c4b0ff4c..2e37a32e 100644 --- a/po/ChangeLog +++ b/po/ChangeLog @@ -1,3 +1,7 @@ +2004-11-17 Bart Hakvoort + + * POTFILES.in: added src/GParted_Core.cc + 2004-11-09 Miloslav Trmac * cs.po: Updated Czech translation. diff --git a/po/POTFILES.in b/po/POTFILES.in index 3d80b602..becf1547 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in @@ -8,6 +8,7 @@ src/Dialog_Partition_Info.cc src/Dialog_Partition_New.cc src/Dialog_Partition_Resize_Move.cc src/Dialog_Progress.cc +src/GParted_Core.cc src/Operation.cc src/Partition.cc src/TreeView_Detail.cc diff --git a/src/ext3.cc b/src/ext3.cc index 70e08ce3..51af6b45 100644 --- a/src/ext3.cc +++ b/src/ext3.cc @@ -27,7 +27,7 @@ FS ext3::get_filesystem_support( ) fs .filesystem = "ext3" ; - if ( ! system( "which tune2fs 1>/dev/null 2>/dev/null" ) ) ; + if ( ! system( "which tune2fs 1>/dev/null 2>/dev/null" ) ) fs .create = true ; fs .resize = true ; diff --git a/src/fat32.cc b/src/fat32.cc index 928ef87c..e7123d3e 100644 --- a/src/fat32.cc +++ b/src/fat32.cc @@ -26,7 +26,12 @@ FS fat32::get_filesystem_support( ) FS fs ; fs .filesystem = "fat32" ; - fs .create = true ; + + //find out if we can create fat32 filesystems + if ( ! system( "which mkdosfs 1>/dev/null 2>/dev/null" ) ) + fs .create = true ; + + //resing of start and endpoint are provided by libparted fs .resize = true ; fs .move = true ; @@ -35,35 +40,7 @@ FS fat32::get_filesystem_support( ) bool fat32::Create( const Glib::ustring device_path, const Partition & new_partition ) { - bool return_value = false ; - - if ( open_device_and_disk( device_path, device, disk ) ) - { - PedPartition *c_part = NULL ; - PedFileSystemType *fs_type = NULL ; - PedFileSystem *fs = NULL ; - - c_part = ped_disk_get_partition_by_sector( disk, (new_partition .sector_end + new_partition .sector_start) / 2 ) ; - if ( c_part ) - { - fs_type = ped_file_system_type_get( "fat32" ) ; - if ( fs_type ) - { - fs = ped_file_system_create( & c_part ->geom, fs_type, NULL ); - if ( fs ) - { - if ( ped_partition_set_system(c_part, fs_type ) ) - return_value = Commit( disk ) ; - - ped_file_system_close( fs ); - } - } - } - - close_device_and_disk( device, disk ) ; - } - - return return_value ; + return Execute_Command( "mkdosfs -F32 " + new_partition .partition ) ; } bool fat32::Resize( const Glib::ustring device_path, const Partition & partition_old, const Partition & partition_new )