mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-01-24 14:23:36 -05:00
patch from Phenom to encode non standard character in file names correctly in RS links
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6600 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
1273e8179f
commit
5aedf393b2
@ -698,7 +698,32 @@ QString RetroShareLink::title() const
|
||||
|
||||
static QString encodeItem(QString item)
|
||||
{
|
||||
return item.replace(" ", "%20").replace("&", "%26").replace("#", "%23").replace("\"", "%22");
|
||||
return item
|
||||
// .replace("{", "%"+QString::number((int)'{'))
|
||||
// .replace("}", "%"+QString::number((int)'}'))
|
||||
// .replace("[", "%"+QString::number((int)'['))
|
||||
// .replace("]", "%"+QString::number((int)']'))
|
||||
// .replace("^", "%"+QString::number((int)'^'))
|
||||
// .replace("~", "%"+QString::number((int)'~'))
|
||||
// .replace(";", "%"+QString::number((int)';'))
|
||||
// .replace(":", "%"+QString::number((int)':'))
|
||||
// .replace("=", "%"+QString::number((int)'='))
|
||||
// .replace("+", "%"+QString::number((int)'+'))
|
||||
// .replace("$", "%"+QString::number((int)'$'))
|
||||
// .replace(",", "%"+QString::number((int)','))
|
||||
// .replace("\"", "%"+QString::number((int)'\"'))
|
||||
// .replace("|", "%"+QString::number((int)'|'))
|
||||
// .replace("?", "%"+QString::number((int)'?'))
|
||||
// .replace("@", "%"+QString::number((int)'@'))
|
||||
.replace("&", "%"+QString::number((int)'&'))//Not necessary: only for text link
|
||||
.replace("/", "%"+QString::number((int)'/'))
|
||||
// .replace(" ", "%"+QString::number((int)' '))
|
||||
.replace("#", "%"+QString::number((int)'#'))
|
||||
// .replace("£", "%"+QString::number((int)'£'))
|
||||
// .replace("µ", "%"+QString::number((int)'µ'))
|
||||
// .replace("§", "%"+QString::number((int)'§'))
|
||||
// .replace("!", "%"+QString::number((int)'!'))
|
||||
;
|
||||
}
|
||||
|
||||
QString RetroShareLink::toString() const
|
||||
|
Loading…
Reference in New Issue
Block a user