KBookmarkManager::slotEditBookmarks is supposed to run keditbookmarks, but does not emit any errors when if it's missing
This makes "Edit bookmarks" menu fail silently in applications that use KBookmarks (e.g. krdc, konsole)
BUG: 303830
dfaure |
Frameworks |
KBookmarkManager::slotEditBookmarks is supposed to run keditbookmarks, but does not emit any errors when if it's missing
This makes "Edit bookmarks" menu fail silently in applications that use KBookmarks (e.g. krdc, konsole)
BUG: 303830
Automatic diff as part of commit; lint not applicable. |
Automatic diff as part of commit; unit tests not applicable. |
This is not a comment about the content of the patch, but if it closed that bug, please change the reference to the bug with a simple line containing:
BUG: xxxxxx
Call startDetached without an object since it's static (my bad, QProcess object does return an error but it's UnknownError and I assume should be seeing FailedToStart; there doesn't seem to be any other interesting errors so probably return value from startDetached should be enough)
src/kbookmarkmanager.cpp | ||
---|---|---|
335 | Yeah it returns unknown error, my mistake, I suppose I should just switch back to call without object since it's a static method |
src/kbookmarkmanager.cpp | ||
---|---|---|
341 | Uh oh, I'd assume startKEditBookmarks should be const (which I forgot) since it doesn't change the object, yet we need to emit non-const singal error. So should it be const or not? Also, I'm looking at slotEditBookmarks and slotEditBookmarksAtAddress, and don't understand why those weren't const, since they don't have side-effects too, although I might be missing something since I'm not too familiar with Qt. |
src/kbookmarkmanager.cpp | ||
---|---|---|
341 | i'd go for non const as the other two methods, yes they could be const since they're not modyfing the object, i guess what the original author had in mind is a meaning of "this changes things eventually" so that's why it isn't const, or maybe it was just a mistake :D |
Good fix, thanks.
src/kbookmarkmanager.cpp | ||
---|---|---|
341 | The author is me, and the calling methods are slots (which are typically not const) ;) |