Jump to content

Translations:Development/Tutorials/Qt4 Ruby Tutorial/Chapter 04/21/fi: Difference between revisions

From KDE TechBase
Centerlink (talk | contribs)
Created page with "Kuten useimmat käyttöliittymäkomponentit, se vain välittää '''<tt>parent</tt>'''-parametrin [http://doc.qt.nokia.com/latest/qwidget.html Qt::Widget]-konstruktorille. (Jos o..."
 
(No difference)

Latest revision as of 11:53, 27 August 2011

Information about message (contribute)
This message has no documentation. If you know where or how this message is used, you can help other translators by adding documentation to this message.
Message definition (Development/Tutorials/Qt4 Ruby Tutorial/Chapter 04)
Like most widgets, it just passes on the '''<tt>parent</tt>''' parameter to the [http://doc.qt.nokia.com/latest/qwidget.html Qt::Widget] constructor. (If you're new to Ruby, calling '''<tt>super</tt>''' without any parameters will automatically pass on any parameters a method received to the superclass's method of the same name. ''Update'': Apparently, it's also important to leave off the parentheses — calling '''<tt>super()</tt>''' will call the superclass's method of the same name with an empty parameter list.)

Kuten useimmat käyttöliittymäkomponentit, se vain välittää parent-parametrin Qt::Widget-konstruktorille. (Jos olet uusi Ruby-kielessä, niin kutsumalla super ilman mitään parametreja välitetään automaattisesti kaikki metodin vastaanottamat parametrit superluokan samannimiselle metodille. Update: Ilmeisesti on myös tärkeää jättää pois sulkeet — kutsumalla super() kutsutaan superluokan samanniminen metodi tyhjällä parametriluettelolla.)