Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: src/Utils.h

Issue 10459038: Clean up and fix Utils::ToUTF8String() and Utils::ToUTF16String() (Closed)
Patch Set: Created May 14, 2013, 1:54 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/DefaultWebRequestWinInet.cpp ('k') | src/Utils.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * This file is part of Adblock Plus <http://adblockplus.org/>, 2 * This file is part of Adblock Plus <http://adblockplus.org/>,
3 * Copyright (C) 2006-2013 Eyeo GmbH 3 * Copyright (C) 2006-2013 Eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 10 matching lines...) Expand all
21 #include <v8.h> 21 #include <v8.h>
22 22
23 namespace AdblockPlus 23 namespace AdblockPlus
24 { 24 {
25 namespace Utils 25 namespace Utils
26 { 26 {
27 std::string Slurp(std::ios& stream); 27 std::string Slurp(std::ios& stream);
28 std::string FromV8String(v8::Handle<v8::Value> value); 28 std::string FromV8String(v8::Handle<v8::Value> value);
29 v8::Local<v8::String> ToV8String(const std::string& str); 29 v8::Local<v8::String> ToV8String(const std::string& str);
30 #ifdef _WIN32 30 #ifdef _WIN32
31 std::wstring ToUTF16String(const std::string& str, unsigned long length); 31 std::wstring ToUTF16String(const std::string& str);
32 std::string ToUTF8String(const std::wstring& str, unsigned long length); 32 std::string ToUTF8String(const std::wstring& str);
33 std::wstring CanonizeUrl(const std::wstring url); 33 std::wstring CanonizeUrl(const std::wstring url);
34 std::wstring TrimString(std::wstring text); 34 std::wstring TrimString(std::wstring text);
35 #endif 35 #endif
36 } 36 }
37 } 37 }
38 38
39 #endif 39 #endif
OLDNEW
« no previous file with comments | « src/DefaultWebRequestWinInet.cpp ('k') | src/Utils.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld