Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Network
KIO Extras
Commits
b58c3d0e
Commit
b58c3d0e
authored
Dec 31, 2020
by
Stefan Brüns
Committed by
Christoph Cullmann
Jan 15, 2021
Browse files
Use QStringLiteral for verbatim QStrings in UDS entries
parent
46b39f1a
Changes
3
Hide whitespace changes
Inline
Side-by-side
man/kio_man.cpp
View file @
b58c3d0e
...
...
@@ -704,7 +704,7 @@ void MANProtocol::stat( const QUrl& url)
entry
.
reserve
(
3
);
entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_NAME
,
title
);
entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_FILE_TYPE
,
S_IFREG
);
entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_MIME_TYPE
,
QString
::
fromLatin1
(
"text/html"
));
entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_MIME_TYPE
,
QString
Literal
(
"text/html"
));
statEntry
(
entry
);
finished
();
...
...
@@ -1385,7 +1385,7 @@ void MANProtocol::listDir(const QUrl &url)
uds_entry
.
reserve
(
3
);
uds_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_NAME
,
*
it
);
uds_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_FILE_TYPE
,
S_IFREG
);
uds_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_MIME_TYPE
,
QString
::
fromLatin1
(
"text/html"
));
uds_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_MIME_TYPE
,
QString
Literal
(
"text/html"
));
uds_entry_list
.
append
(
uds_entry
);
}
...
...
mtp/kio_mtp.cpp
View file @
b58c3d0e
...
...
@@ -283,7 +283,7 @@ void MTPSlave::stat(const QUrl &url)
// root
if
(
pathItems
.
size
()
<
1
)
{
entry
.
reserve
(
4
);
entry
.
fastInsert
(
UDSEntry
::
UDS_NAME
,
Q
Latin1
String
(
"mtp:///"
));
entry
.
fastInsert
(
UDSEntry
::
UDS_NAME
,
QString
Literal
(
"mtp:///"
));
entry
.
fastInsert
(
UDSEntry
::
UDS_FILE_TYPE
,
S_IFDIR
);
entry
.
fastInsert
(
UDSEntry
::
UDS_ACCESS
,
S_IRUSR
|
S_IRGRP
|
S_IROTH
|
S_IXUSR
|
S_IXGRP
|
S_IXOTH
);
entry
.
fastInsert
(
UDSEntry
::
UDS_MIME_TYPE
,
QStringLiteral
(
"inode/directory"
));
...
...
smb/smbcdiscoverer.cpp
View file @
b58c3d0e
...
...
@@ -20,8 +20,8 @@ public:
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_FILE_TYPE
,
S_IFDIR
);
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_ACCESS
,
(
S_IRUSR
|
S_IXUSR
|
S_IRGRP
|
S_IXGRP
|
S_IROTH
|
S_IXOTH
));
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_URL
,
url
());
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_MIME_TYPE
,
QString
::
fromLatin1
(
"application/x-smb-server"
));
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_ICON_NAME
,
"network-server"
);
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_MIME_TYPE
,
QString
Literal
(
"application/x-smb-server"
));
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_ICON_NAME
,
QStringLiteral
(
"network-server"
)
)
;
}
QString
url
()
...
...
@@ -51,7 +51,7 @@ public:
{
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_FILE_TYPE
,
S_IFDIR
);
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_ACCESS
,
(
S_IRUSR
|
S_IRGRP
|
S_IROTH
|
S_IXUSR
|
S_IXGRP
|
S_IXOTH
));
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_MIME_TYPE
,
QString
::
fromLatin1
(
"application/x-smb-workgroup"
));
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_MIME_TYPE
,
QString
Literal
(
"application/x-smb-workgroup"
));
m_entry
.
fastInsert
(
KIO
::
UDSEntry
::
UDS_URL
,
url
());
}
...
...
Write
Preview
Supports
Markdown
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