Skip to content

Commit

Permalink
komut satırından dosya acabilme ozelligi
Browse files Browse the repository at this point in the history
  • Loading branch information
erdincyz committed Aug 13, 2024
1 parent 31201a1 commit 338350e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/defter/defter.py
Original file line number Diff line number Diff line change
Expand Up @@ -2804,7 +2804,7 @@ def act_open_def_file(self, zipFilePath=None):
shutil.unpack_archive(zipFilePath, tempDirPath, "zip")
except Exception as e:
self.lutfen_bekleyin_gizle()
hata = self.tr('Could not import file -- "{0:s}"\n{1:s}').format(zipFilePath, str(e))
hata = self.tr('Could not open file -- "{0:s}"\n{1:s}').format(zipFilePath, str(e))
self.log(hata, 5000, 3, dialog=True)
return False

Expand Down Expand Up @@ -11415,8 +11415,13 @@ def calistir():
# Guncelleme: Şimdi pencereyi once de olusturabiliyoruz..
# o yuzden iptal ettik alt satiri,
# TODO: su anda yine bozuk :)

pencere = DefterAnaPencere()

for zipFilePath in sys.argv[1:]:
if zipFilePath.endswith(".def"):
pencere.act_open_def_file(zipFilePath)

# pencere.show()
# burda pencere.show() demiyoruz, DefterAnaPencere().__init__ icinde show var.
# initten cikmadan bazi islemlerden once show cagirmak gerekiyor. (visible view rect sceneRect e atayabilmek icin)
Expand Down

0 comments on commit 338350e

Please sign in to comment.