Skip to content

Commit

Permalink
Replace RabbitCommon::CDir::GetOpenDirectory with QFileDialog::getExi…
Browse files Browse the repository at this point in the history
…stingDirectory etc
  • Loading branch information
KangLin committed Jul 18, 2023
1 parent 43d5dec commit 8126636
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 4 deletions.
6 changes: 6 additions & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
- v1.0.11
+ Replace RabbitCommon::CDir::GetOpenDirectory with QFileDialog::getExistingDirectory etc

- v1.0.10
+ Modify CI

- v1.0.9
+ Add update xml
+ FIX: windows resource
Expand Down
6 changes: 6 additions & 0 deletions ChangeLog_zh_CN.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
- v1.0.11
+ 用 QFileDialog::getExistingDirectory 替换 RabbitCommon::CDir::GetOpenDirectory 等

- v1.0.10
+ 修改自动化编译

- v1.0.9
+ 增加:更新 xml 文件
+ 修复: windows 资源
Expand Down
4 changes: 2 additions & 2 deletions Src/FrmStickyList.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ void CFrmStickyList::slotLoad()
RabbitCommon::CDir::Instance()->GetDirUserData()
+ QDir::separator() + "Sticky").toString();
QFileInfo fi(szFile);
szFile = RabbitCommon::CDir::GetOpenFileName(this, tr("Open sticky"), fi.path()); // QFileDialog::getOpenFileName();
szFile = QFileDialog::getOpenFileName(this, tr("Open sticky"), fi.path()); // QFileDialog::getOpenFileName();
if(szFile.isEmpty())
return;
Load(szFile);
Expand Down Expand Up @@ -131,7 +131,7 @@ void CFrmStickyList::slotSave()
RabbitCommon::CDir::Instance()->GetDirUserData()
+ QDir::separator() + "Sticky").toString();
QFileInfo fi(szFile);
szFile = RabbitCommon::CDir::GetSaveFileName(this, tr("Save sticky"), fi.path());
szFile = QFileDialog::getSaveFileName(this, tr("Save sticky"), fi.path());
if(szFile.isEmpty())
return;
}
Expand Down
4 changes: 2 additions & 2 deletions Src/FrmTasksList.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,14 +97,14 @@ int CFrmTasksList::Load(QString szFile)

void CFrmTasksList::slotLoad()
{
QString szFile = RabbitCommon::CDir::GetOpenFileName(this,
QString szFile = QFileDialog::getOpenFileName(this,
tr("Load"), QString(), tr("xml(*.xml);;All files(*.*)"));
Load(szFile);
}

void CFrmTasksList::slotSaveAs()
{
QString szFile = RabbitCommon::CDir::GetSaveFileName(this,
QString szFile = QFileDialog::getSaveFileName(this,
tr("Save as ..."), QString(), "*.xml");
if(szFile.lastIndexOf(".xml") == -1)
szFile += ".xml";
Expand Down

0 comments on commit 8126636

Please sign in to comment.