I'm building a notepad application using the QT libraries. I am looking for a way to create a "save" function. I have the "save as..." function working because I figured out how to get the dialog to come up and then choose where to save it. But now I want to create just a plain 'save' button that doesn't ask where to save, it just saves to its current file.

I just need to know how to grab the opened file's name and just substitute that for the [code]QFileDialog::getopenfilename()[code]...

Pseudocode would be something like:

Code:
...
QString saveName=(this File's Name);
save file without asking under saveName;
...