Commit 3836232c authored by Curtis Gedak's avatar Curtis Gedak
Browse files

Prevent a copied partition from being pasted into an existing partition

svn path=/trunk/; revision=972
parent 1582dc3c
2008-11-19 Curtis Gedak <gedakc@gmail.com>
* src/Win_GParted.cc: Fixed dangerous copy and paste problem.
- Prevent a copied partition from being pasted into an existing
partition.
* src/Win_GParted.cc: Added language length conditional Undo display.
- If translated language is relatively long, then
split the "Resize/Move" toolbar button text into two lines, and
......
......@@ -896,7 +896,8 @@ void Win_GParted::set_valid_operations()
if ( ! copied_partition .get_path() .empty() &&
copied_partition .get_length() <= selected_partition .get_length() &&
selected_partition .status == GParted::STAT_REAL &&
copied_partition != selected_partition )
copied_partition != selected_partition &&
selected_partition .type == GParted::TYPE_UNALLOCATED )
allow_paste( true ) ;
//see if we can somehow check/repair this file system....
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment