restore this file functionality does not work

Bug #947006 reported by Pim Vullers
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Scratch
Fix Released
High
Mario Guerriero

Bug Description

When I have a file, I make some changes (adding text) I choose to restore the file. However, the file does not get restored to its original state.

Revision history for this message
Mario Guerriero (mefrio-g) wrote :

What version do you have? It works with the latest revision

Changed in scratch:
status: New → Invalid
Revision history for this message
Pim Vullers (pimvullers) wrote :

Attached the output of scratch with:
 - opening test.txt
 - removing a line
 - trying to restore
 - closing scratch

----- test.txt (there used to be one more line)

hdhakj
kdjhaksd
hoi

Revision history for this message
Pim Vullers (pimvullers) wrote :

This was done with trunk of scratch and granite, latest releases of glib (2.31.18), gtk+ (3.3.16) and gtksourceview (3.2.3).

Changed in scratch:
status: Invalid → New
Revision history for this message
Mario Guerriero (mefrio-g) wrote :

It happens only when you open a file with "scratch file.txt"

Changed in scratch:
status: New → Confirmed
importance: Undecided → High
milestone: none → 1.1
Changed in scratch:
assignee: nobody → Mario Guerriero (mefrio-g)
status: Confirmed → Fix Committed
Revision history for this message
Pim Vullers (pimvullers) wrote :

It is now indeed fixed for opening a file using "scratch file.txt".
However opening a file form the welcome screen, the file browser (plugin) or the open button still does not give the desired behaviour.

Changed in scratch:
status: Fix Committed → In Progress
Revision history for this message
Mario Guerriero (mefrio-g) wrote :

now it seems that this bug is only for the file manager plugin.

Revision history for this message
xapantu (xapantu) wrote :

Yes, the code was misplaced, it was in open instead of open_file, that's why it wasn't always working. So, I just moved Mario's fix, it should work now.

Changed in scratch:
status: In Progress → Fix Committed
Revision history for this message
Mario Guerriero (mefrio-g) wrote :

No sorry, you were right. Thank you

Revision history for this message
Mario Guerriero (mefrio-g) wrote :

Thanks xapanatu, I was pushing in the same moment you pushed :)

Changed in scratch:
milestone: luna-beta1 → 1.1
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.