title: Kivy: pass data to another class
body: <p>I`m trying to make a simple GUI with Kivy(1.9) using a popup to change some options from a list and save it to a db, for example. When i call popup(), Python(3.4.5) crash..</p>
  
  <p>main.py:</p>
  
  <pre><code>from kivy.app import App
  from kivy.uix.button import Button
  from kivy.uix.popup import Popup
  from kivy.properties import ListProperty
  from kivy.lang import Builder
  
  Builder.load_string('''
  &lt;PopView&gt;:
      title: 'Popup'
      size_hint: (.8, .8)
      Button:
          text: 'Save'
  ''')
  
  class MainApp(App):
  
      def build(self):
          b = Button(text='click to open popup')
          b.bind(on_click=self.view_popup())
          return b
  
      def view_popup(self):
          a=PopView()
          a.data=[1,2,3,4] #e.g.
          a.open()
  
  class PopView(Popup):
  
      def __init__(self):
          self.data = ListProperty()
  
      def save_data(self):
          #db.query(self.data)
          pass
  
  
  if __name__ in ('__main__', '__android__'):
      MainApp().run()
  </code></pre>