Linking components from 2 different classes

  • (2 Pages)
  • +
  • 1
  • 2

18 Replies - 515 Views - Last Post: 20 June 2020 - 11:35 AM Rate Topic: -----

#16 NormR   User is online

  • D.I.C Lover
  • member icon

Reputation: 832
  • View blog
  • Posts: 6,392
  • Joined: 25-December 13

Re: Linking components from 2 different classes

Posted 20 June 2020 - 11:22 AM

Quote

static buttons are there to transcend to the extending class to do what is required

Why does GoToClass need to extend Start if the variables are static?
Without static the change would be to use the classname with the variable name: Start.buttonName
Was This Post Helpful? 1
  • +
  • -

#17 idlewild   User is offline

  • New D.I.C Head

Reputation: 3
  • Posts: 35
  • Joined: 19-June 20

Re: Linking components from 2 different classes

Posted 20 June 2020 - 11:25 AM

but the call to the action taking classes are by new

the extending class not only extends the root class it listens to changes made to buttons via ActionListener interface.
Was This Post Helpful? 0
  • +
  • -

#18 NormR   User is online

  • D.I.C Lover
  • member icon

Reputation: 832
  • View blog
  • Posts: 6,392
  • Joined: 25-December 13

Re: Linking components from 2 different classes

Posted 20 June 2020 - 11:33 AM

Why does GoToClass need to extend Start?
Why can't st2 be GoToClass?

This post has been edited by NormR: 20 June 2020 - 11:35 AM

Was This Post Helpful? 0
  • +
  • -

#19 idlewild   User is offline

  • New D.I.C Head

Reputation: 3
  • Posts: 35
  • Joined: 19-June 20

Re: Linking components from 2 different classes

Posted 20 June 2020 - 11:35 AM

after a thorough thinking and "assuming" the root class is the first to implement ActionListener

yes otherwise it is futile imo
Was This Post Helpful? 0
  • +
  • -

  • (2 Pages)
  • +
  • 1
  • 2