def wallSelected(self, obj, item): #self.previewBox.clear() #edjeObj = Layout(self.previewBox, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) edjeObj = Edje(self.previewBox.evas, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) filePath = item.data["filePath"] edjeObj.file_set(filePath, "e/desktop/background") edjeObj.show() self.previewBox.content_set(edjeObj) self.currentPreview = edjeObj self.selectedWall = filePath
def themeSelected(self, obj, item): #self.previewBox.clear() edjeObj = Edje(self.evas, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) filePath = item.data["filePath"] try: edjeObj.file_set(filePath, "moksha/preview") except: edjeObj.file_set(filePath, "e/desktop/background") edjeObj.show() self.previewBox.content_set(edjeObj) self.currentPreview = edjeObj self.selectedTheme = filePath
def addTheme(self, themeFile, ourPath): edjeObj = Edje(self.evas, size_hint_weight=EXPAND_BOTH, size_hint_align=FILL_BOTH) try: edjeObj.file_set("%s/%s" % (ourPath, themeFile), "moksha/preview") except: edjeObj.file_set("%s/%s" % (ourPath, themeFile), "e/desktop/background") edjeObj.show() listItem = self.themeList.item_append("%s" % themeFile, edjeObj, callback=self.themeSelected) listItem.data["filePath"] = "%s%s" % (ourPath, themeFile) listItem.selected_set(True) self.foundThemes.append("%s%s" % (ourPath, themeFile)) self.themeSelected(None, listItem)