include NFC changes required for transferring data
This commit is contained in:
@@ -1,18 +1,18 @@
|
||||
'''
|
||||
'''
|
||||
from kivy.core import core_select_lib
|
||||
from kivy.uix.widget import Widget
|
||||
from kivy.properties import ObjectProperty
|
||||
from kivy.factory import Factory
|
||||
|
||||
__all__ = ('NFCBase', 'NFCScanner')
|
||||
|
||||
class NFCBase(Widget):
|
||||
''' This is the base Abstract definition class that the actual hardware dependent
|
||||
implementations would be based on. If you want to define a feature that is
|
||||
accissible and implemented by every platform implementation then define that
|
||||
method in this class.
|
||||
'''
|
||||
|
||||
payload = ObjectProperty(None)
|
||||
'''This is the data gotten from the tag.
|
||||
'''
|
||||
|
||||
def nfc_init(self):
|
||||
''' Initialize the adapter
|
||||
''' Initialize the adapter.
|
||||
'''
|
||||
pass
|
||||
|
||||
@@ -27,17 +27,18 @@ class NFCBase(Widget):
|
||||
pass
|
||||
|
||||
def nfc_enable_exchange(self, data):
|
||||
''' Start sending data
|
||||
''' Enable P2P Ndef exchange
|
||||
'''
|
||||
pass
|
||||
|
||||
def nfc_disable_exchange(self):
|
||||
''' Disable/Stop ndef exchange
|
||||
''' Disable/Stop P2P Ndef exchange
|
||||
'''
|
||||
pass
|
||||
|
||||
# load NFCScanner implementation
|
||||
|
||||
NFCScanner = core_select_lib('nfc_scanner', (
|
||||
NFCScanner = core_select_lib('nfc_manager', (
|
||||
# keep the dummy implementtation as the last one to make it the fallback provider.NFCScanner = core_select_lib('nfc_scanner', (
|
||||
('android', 'scanner_android', 'ScannerAndroid'),
|
||||
('dummy', 'scanner_dummy', 'ScannerDummy')), True, 'electrum_gui.kivy')
|
||||
|
||||
Reference in New Issue
Block a user