1009 return |
1009 return |
1010 |
1010 |
1011 filename = aw.getFileName() |
1011 filename = aw.getFileName() |
1012 if renameModule: |
1012 if renameModule: |
1013 offset = None |
1013 offset = None |
|
1014 if os.path.basename(filename) == "__init__.py": |
|
1015 filename = os.path.dirname(filename) |
1014 selectedText, _ = os.path.splitext(os.path.basename(filename)) |
1016 selectedText, _ = os.path.splitext(os.path.basename(filename)) |
1015 else: |
1017 else: |
1016 line, index, line1, index1 = aw.getSelection() |
1018 line, index, line1, index1 = aw.getSelection() |
1017 if line != line1: |
1019 if line != line1: |
1018 # selection span more than one line |
1020 # selection span more than one line |