Ensure the filedialog shows the initial filename
Whenever the selection changes it will call panelSelectionDidChange even if the panel is not visible which causes it to overwrite our chosen initial file with "untitled". Therefore we only set the name when the panel is actually visible. Change-Id: I09f7ebabce5c2139a7f74b953391d39dfad65db2 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>bb10
parent
76de1ac0a4
commit
cbece1e8c4
|
|
@ -446,7 +446,7 @@ static QString strippedText(QString s)
|
|||
- (void)panelSelectionDidChange:(id)sender
|
||||
{
|
||||
Q_UNUSED(sender);
|
||||
if (mHelper) {
|
||||
if (mHelper && [mSavePanel isVisible]) {
|
||||
QString selection = QCFString::toQString([[mSavePanel URL] path]);
|
||||
if (selection != mCurrentSelection) {
|
||||
*mCurrentSelection = selection;
|
||||
|
|
|
|||
Loading…
Reference in New Issue