Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Jean-Francois Dockes
recoll
Commits
f0d193e5
Commit
f0d193e5
authored
Feb 23, 2017
by
Jean-Francois Dockes
Browse files
Reopen db before showing indexed MIME types, explain empty list
parent
5c46dbf7
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/qtgui/rclm_wins.cpp
View file @
f0d193e5
...
...
@@ -346,9 +346,11 @@ void RclMain::showMissingHelpers()
void
RclMain
::
showActiveTypes
()
{
if
(
rcldb
==
0
)
{
string
reason
;
bool
maindberror
;
if
(
!
maybeOpenDb
(
reason
,
true
,
&
maindberror
))
{
QMessageBox
::
warning
(
0
,
tr
(
"Error"
),
tr
(
"Index not open"
),
u8s2qs
(
reason
),
QMessageBox
::
Ok
,
QMessageBox
::
NoButton
);
return
;
...
...
@@ -407,9 +409,14 @@ void RclMain::showActiveTypes()
editor
->
setReadOnly
(
true
);
dialog
.
horizontalLayout
->
addWidget
(
editor
);
for
(
set
<
string
>::
const_iterator
it
=
mtypesfromdbconf
.
begin
();
it
!=
mtypesfromdbconf
.
end
();
it
++
)
{
editor
->
append
(
QString
::
fromUtf8
(
it
->
c_str
()));
if
(
mtypesfromdbconf
.
empty
())
{
editor
->
append
(
tr
(
"Types list empty: maybe wait for indexing to "
"progress?"
));
}
else
{
for
(
set
<
string
>::
const_iterator
it
=
mtypesfromdbconf
.
begin
();
it
!=
mtypesfromdbconf
.
end
();
it
++
)
{
editor
->
append
(
QString
::
fromUtf8
(
it
->
c_str
()));
}
}
editor
->
moveCursor
(
QTextCursor
::
Start
);
editor
->
ensureCursorVisible
();
...
...
src/qtgui/recoll.h
View file @
f0d193e5
...
...
@@ -55,6 +55,10 @@ inline std::string qs2utf8s(const QString& qs)
{
return
std
::
string
((
const
char
*
)
qs
.
toUtf8
());
}
inline
QString
u8s2qs
(
const
std
::
string
us
)
{
return
QString
::
fromUtf8
(
us
.
c_str
());
}
/** Specialized version of the qt file dialog. Can't use getOpenFile()
etc. cause they hide dot files... */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment