flist is only used to access the application root. Change it to master. Then text can directly pass the test root.
name and path are the split apart pieces of the module path, minus '.py', which are promptly rejoined, with '.py'. Callers always start valid path and have to split it and delete '.py' for the call. Let them pass the full path. A side-effect is that the browser will not work with a file without '.py'.
ModuleBrowser can them split off the filename and remove a '.p?' extension, if present.
The patch will have to change both .__init__ and callers, and ideally should somehow test that everything works.
Menu item 'Module Browser' invokes '<<open-class-browser>>', which calls Editor_Window.open_module_browser. If the window is an actual editor, its path is used; otherwise open_module is called. In either case, ModuleBrowser is called with flist and path pieces.
PathBrowser subclasses ModuleBrowser. Menu item 'Path Browser' invokes '<<open-path-browser>>', which calls Editor_Window.open_path_browser, which calles PathBrowser. PathBrowser.__init__'s only parameter is flist and it does not call ModuleBrowser.__init__. So the APIs are independent and can be modified or not separately.
For ModuleBrowser, changing flist to master and changing (name, path) to to filepath can be done independently.
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
The text was updated successfully, but these errors were encountered: