Use native Mac OSX Dialog to select directory for screenshot

Bug #1300917 reported by henrysky
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Stellarium
Fix Released
Low
henrysky

Bug Description

Use native Mac OSX Dialog to select directory for screenshot
QTBUG-16722 has already been fixed (For reference: http://bugreports.qt.nokia.com/browse/QTBUG-16722)

In ConfigurationDialog.cpp, delete line435-438 and line440
I have tested it on my Mac OSX 10.9.2 and it works OK

The code:
void ConfigurationDialog::browseForScreenshotDir()
{
 QString oldScreenshorDir = StelFileMgr::getScreenshotDir();
  QString newScreenshotDir = QFileDialog::getExistingDirectory(NULL, q_("Select screenshot directory"), oldScreenshorDir, QFileDialog::ShowDirsOnly);

 if (!newScreenshotDir.isEmpty()) {
  // remove trailing slash
  if (newScreenshotDir.right(1) == "/")
   newScreenshotDir = newScreenshotDir.left(newScreenshotDir.length()-1);

  ui->screenshotDirEdit->setText(newScreenshotDir);
 }
}

Tags: mac-os-x

Related branches

Revision history for this message
henrysky (henry-leung-2010) wrote :

A screenshot to prove it is OK

description: updated
Revision history for this message
henrysky (henry-leung-2010) wrote :

AddRemoveLandscapeDialog.cpp also has this problem
Start from line 116
I have tested and It also works ok for using native Mac OSX dialog

Revision history for this message
Alexander Wolf (alexwolf) wrote :

Can you prepare patch (bzr diff > osx.patch)?

Changed in stellarium:
milestone: none → 0.13.0
assignee: nobody → henrysky (henry-leung-2010)
importance: Undecided → Low
tags: added: mac-os-x
Revision history for this message
Alexander Wolf (alexwolf) wrote :

A fix has been committed as revision 6691 of the trunk branch in Stellarium's Bazaar repository at Launchpad:
http://bazaar.launchpad.net/~stellarium/stellarium/trunk/revision/6691

Changed in stellarium:
status: New → Fix Committed
Revision history for this message
henrysky (henry-leung-2010) wrote :

Sorry, I don't know how to create the patch file...
But anyway, you know what I mean and fixed it in revision 6691

Revision history for this message
Alexander Wolf (alexwolf) wrote :

You can use command bzr diff > osx.patch in Terminal.app, where osx.patch is file with patch.

Changed in stellarium:
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.