|
|
#1 |
|
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 776
Karma: 2751519
Join Date: Jul 2010
Location: UK
Device: PW2, Nexus7
|
Using Class Variable in Def
In a plugin ui.py I have:
Code:
class InterfacePlugin(InterfaceAction):
name = 'Repository Links'
action_spec = (name, None, 'Link book to supplementary material', None)
Code:
def show_ui(self):
:
return error_dialog(self.gui, name, 'Repository file not found', show=True)
So, how do I refer to name within a def? |
|
|
|
|
|
#2 |
|
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,646
Karma: 28549046
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
self.name
|
|
|
|
| Advert | |
|
|
![]() |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Variable payments come to eBooks | WhichP | News | 4 | 08-04-2012 04:52 PM |
| PRS-650 SD Card Importance? SDHC, SDHC Class 4, Class 10 etc is it important | Renji | Sony Reader | 11 | 12-03-2011 01:30 PM |
| PATH variable in Windows | kapsi | Calibre | 3 | 05-16-2011 06:12 PM |
| Questions About def get_browser(self) | Finbar127 | Recipes | 6 | 02-24-2011 10:36 PM |