Gambas-it

Gambas dal mondo esterno => Mailing List => Topic aperto da: vuott - 16 Giugno 2017, 15:52:34

Titolo: DesktopWindow.Name: risultato inaspettato
Inserito da: vuott - 16 Giugno 2017, 15:52:34
https://www.mail-archive.com/gambas-user@lists.sourceforge.net/msg39643.html

Titolo: Re:DesktopWindow.Name: risultato inaspettato
Inserito da: Gianluigi - 16 Giugno 2017, 22:55:55
La documentazione di Gambas circa DesktopWindow.VisibleName (gb.desktop) recita:
Restituisce il nome visibile della finestra, vale a dire il titolo della finestra come visualizzato dal gestore di finestra.
Il nome visibile può essere diverso dal nome, quando due o più finestre hanno lo stesso nome.


Allora ho creato tre diverse applicazioni con una finestra dello stesso nome FOO le ho lanciate e poi ne ho lanciato una quarta con questo codice.
Io non noto differenze nell'output, bhoo!
Codice: [Seleziona]
Public Sub Form_Open()

  Dim w As DesktopWindow
 
  For Each w In Desktop.Windows
    Print w.Name
  Next
  For Each w In Desktop.Windows
    Print w.VisibleName
  Next

End

L'output:

Codice: [Seleziona]
Scrivania
FOO
FMain.form - App-3 0.0.1 - Gambas 3 - DEVELOPMENT VERSION, USE AT YOUR OWN RISK!
FOO
FMain.form - App-2 0.0.1 - Gambas 3 - DEVELOPMENT VERSION, USE AT YOUR OWN RISK!
FOO
FMain.form - App-1 0.0.1 - Gambas 3 - DEVELOPMENT VERSION, USE AT YOUR OWN RISK!
FMain.class - Write 0.0.1 - Gambas 3 - DEVELOPMENT VERSION, USE AT YOUR OWN RISK!





Scrivania
FOO
FMain.form - App-3 0.0.1 - Gambas 3 - DEVELOPMENT VERSION, USE AT YOUR OWN RISK!
FOO
FMain.form - App-2 0.0.1 - Gambas 3 - DEVELOPMENT VERSION, USE AT YOUR OWN RISK!
FOO
FMain.form - App-1 0.0.1 - Gambas 3 - DEVELOPMENT VERSION, USE AT YOUR OWN RISK!
FMain.class - Write 0.0.1 - Gambas 3 - DEVELOPMENT VERSION, USE AT YOUR OWN RISK!

 :ciao: :ciao: