Merge pull request #251 from cuu/gcores

Gcores
This commit is contained in:
GNU 2019-07-11 22:38:00 +08:00 committed by GitHub
commit af8f80736e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -19,7 +19,7 @@ from icon_item import IconItem
from page import Page,PageStack
from title_bar import TitleBar
from foot_bar import FootBar
from constants import Width,Height,bg_color
from constants import Width,Height
from util_funcs import midRect,FileExists,ReplaceSuffix,ReadTheFileContent,CmdClean,MakeExecutable
from keys_def import CurKeys
from label import Label
@ -454,7 +454,7 @@ class MainScreen(Widget):
files = os.listdir(_dir)
for i in sorted(files):
if os.path.isdir(_dir+"/"+i): # TOPLEVEL only is dir
if os.path.isdir(_dir+"/"+i) and i.startswith(".") == False: # TOPLEVEL only is dir
if pglevel == 0:
page = Page()
page._Name = self.ExtraName(i)
@ -567,7 +567,7 @@ class MainScreen(Widget):
cur_page._Icons.append(iconitem)
self.ReadTheDirIntoPages(_dir+"/"+i,pglevel+1,iconitem._LinkPage)
elif os.path.isfile(_dir+"/"+i) and pglevel > 0:
elif os.path.isfile(_dir+"/"+i) and i.startswith(".") == False and pglevel > 0:
if i.lower().endswith(icon_ext):
i2 = self.ExtraName(i)
@ -658,4 +658,3 @@ class MainScreen(Widget):
if hasattr(self._CurrentPage,"_FootMsg"):
self._FootBar.SetLabelTexts(self._CurrentPage._FootMsg)
self._FootBar.Draw()