Silence some warnings due to deprecated stuff. #5
已合併
SlavekB
於 3 年之前 將 1 次代碼提交從 drop/deprecated
合併至 master
Loading…
Reference in new issue
尚未有任何內容
Delete Branch 'drop/deprecated'
Deleting a branch is permanent. It CANNOT be undone. Continue?
25a0916dc0
toacd0abae55
3 年之前acd0abae55
to6b0a83ea18
3 年之前slight UI change for kmouth, come from this:
Into this:
I expect hours of debate for the UI change, like we're often having when I add/change an icon 😉
Good for me – in other applications that have more toolbars, they are also grouped in a submenu. For example Konqueror, KMail – window for a new mail, Kopete,…
I have not tried this PR but I just noticed that in the original KMouth if we hide the menu bar it seems there is no way to bring it back. Am I wrong or am I missing something obvious?
Does this PR do a better job at that? 😄
WIP:Silence some warnings due to deprecated stuff.to Silence some warnings due to deprecated stuff. 3 年之前6b0a83ea18
to4f307f965c
3 年之前4f307f965c
to982ad2ecf3
3 年之前There are incorrectly resolved deprecated NetAccess calls.
See comments below.
tempFile.close();
return TDEIO::NetAccess::upload(tempFile.name(), url);
return TDEIO::NetAccess::file_copy( tempFile.name(), url );
I'm not sure what the differences in behavior between
upload
andfile_copy
are and whether it can't cause unexpected side effects. For example, there is different behavior to overwrite an existing file. In any case,deprecated
is only aupload
with two arguments, so adding a value0
for third argument will ensure thatdeprecated
is not reported and the same behavior is guaranteed.}
if (TDEIO::NetAccess::exists(url)) {
if (url.isLocalFile()) {
This causes an undesirable difference in behavior.
Calling
NetAccess::exists
verifies the existence of the file, whileisLocalFile
tests whether the URL matches the address for the local file, but does not perform an existence test => returns true if the URL matches the local file, whether it exists or not. Returns false if the URL matches a remote file. This is a completely different result than the condition expects.Deprecated calls
NetAccess::exists
are only those with a limited number of arguments. To keep the behavior and solve thedeprecated
warning, you need to add the valuesfalse
and0
for the second and third arguments of the callNetAccess::exists
.982ad2ecf3
to82b737fb73
3 年之前Because the toolbar name is automatically used in the submenu, we probably need to modify it so that the toolbars have a user-readable name instead of a constant and so that these names can be translated.
82b737fb73
to5ce12710c2
3 年之前I'm shortening this PR because I don't wish to spend more time on It.
Ok no problem. It is a good idea that there will not be two things in one commit that are otherwise unrelated.
Simple, clear … ready to merge.
5ce12710c2
into master 3 年之前Reviewers
5ce12710c2
.