Skip to content

Commit

Permalink
Let 'Save as' pre-select the folder of the currently opened file
Browse files Browse the repository at this point in the history
  • Loading branch information
rbreu committed Nov 26, 2023
1 parent 608787d commit d6b7fd7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 3 additions & 1 deletion CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,12 @@ Added
small images and images with an alpha channel will be stored as PNG,
the rest as JPG. In the newly created settings dialog, this
behaviour can be changed to always use PNG (the former behaviour) or
always JPG.
always JPG. To apply this behaviour to your old bee files, you can
save them as new files.
* Antialias/smoothing for displaying images. For images being
displayed at a large zoom factor, smoothing will turn off to make
sure that icons, pixel sprites etc can be viewed correctly.
* "Save as" will now open pre-select the folder of the currently opened file


Fixed
Expand Down
2 changes: 2 additions & 0 deletions beeref/view.py
Original file line number Diff line number Diff line change
Expand Up @@ -366,9 +366,11 @@ def do_save(self, filename, create_new):

def on_action_save_as(self):
self.scene.cancel_crop_mode()
directory = os.path.dirname(self.filename) if self.filename else None
filename, f = QtWidgets.QFileDialog.getSaveFileName(
parent=self,
caption='Save file',
directory=directory,
filter=f'{constants.APPNAME} File (*.bee)')
if filename:
self.do_save(filename, create_new=True)
Expand Down

0 comments on commit d6b7fd7

Please sign in to comment.