getOpenFileName is static method, it will create default file dialog inside, will not use your dialog object. You need to call "exec" to use your dialog with changed label.