Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(222)

Side by Side Diff: core/include/fxcrt/fx_string.h

Issue 1112673002: Revert "Make CFX_WideString::LockBuffer() completely unused." (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | core/src/fpdfdoc/doc_bookmark.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 // Copyright 2014 PDFium Authors. All rights reserved. 1 // Copyright 2014 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 6
7 #ifndef _FX_STRING_H_ 7 #ifndef _FX_STRING_H_
8 #define _FX_STRING_H_ 8 #define _FX_STRING_H_
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after
313 313
314 void Format(FX_LPCSTR lpszFormat, ... ); 314 void Format(FX_LPCSTR lpszFormat, ... );
315 315
316 void FormatV(FX_LPCSTR lpszFormat, va _list argList); 316 void FormatV(FX_LPCSTR lpszFormat, va _list argList);
317 317
318 318
319 void Reserve(FX_STRSIZE len); 319 void Reserve(FX_STRSIZE len);
320 320
321 FX_LPSTR GetBuffer(FX_STRSIZE len); 321 FX_LPSTR GetBuffer(FX_STRSIZE len);
322 322
323 FX_LPSTR LockBuffer();
324
323 void ReleaseBuffer(FX_STRSIZE len = - 1); 325 void ReleaseBuffer(FX_STRSIZE len = - 1);
324 326
325 CFX_ByteString Mid(FX_STRSIZE first) const; 327 CFX_ByteString Mid(FX_STRSIZE first) const;
326 328
327 CFX_ByteString Mid(FX_STRSIZE first, FX_STRSIZE count) const; 329 CFX_ByteString Mid(FX_STRSIZE first, FX_STRSIZE count) const;
328 330
329 CFX_ByteString Left(FX_STRSIZE count) const; 331 CFX_ByteString Left(FX_STRSIZE count) const;
330 332
331 CFX_ByteString Right(FX_STRSIZE count) const; 333 CFX_ByteString Right(FX_STRSIZE count) const;
332 334
(...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after
721 void TrimLeft(); 723 void TrimLeft();
722 724
723 void TrimLeft(FX_WCHAR chTarget); 725 void TrimLeft(FX_WCHAR chTarget);
724 726
725 void TrimLeft(FX_LPCWSTR lpszTargets) ; 727 void TrimLeft(FX_LPCWSTR lpszTargets) ;
726 728
727 void Reserve(FX_STRSIZE len); 729 void Reserve(FX_STRSIZE len);
728 730
729 FX_LPWSTR GetBuffer(FX_STRSIZE len); 731 FX_LPWSTR GetBuffer(FX_STRSIZE len);
730 732
733 FX_LPWSTR LockBuffer();
734
731 void ReleaseBuffer(FX_STRSIZE len = - 1); 735 void ReleaseBuffer(FX_STRSIZE len = - 1);
732 736
733 int GetInteger() const; 737 int GetInteger() const;
734 738
735 FX_FLOAT GetFloat() const; 739 FX_FLOAT GetFloat() const;
736 740
737 FX_STRSIZE Find(FX_LPCWSTR lpszSub, FX_STRSIZE star t = 0) const; 741 FX_STRSIZE Find(FX_LPCWSTR lpszSub, FX_STRSIZE star t = 0) const;
738 742
739 FX_STRSIZE Find(FX_WCHAR ch, FX_STRSIZE start = 0) const; 743 FX_STRSIZE Find(FX_WCHAR ch, FX_STRSIZE start = 0) const;
740 744
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
835 CFX_ByteString FX_UTF8Encode(FX_LPCWSTR pwsStr, FX_STRSIZE len); 839 CFX_ByteString FX_UTF8Encode(FX_LPCWSTR pwsStr, FX_STRSIZE len);
836 inline CFX_ByteString FX_UTF8Encode(FX_WSTR wsStr) 840 inline CFX_ByteString FX_UTF8Encode(FX_WSTR wsStr)
837 { 841 {
838 return FX_UTF8Encode(wsStr.GetPtr(), wsStr.GetLength()); 842 return FX_UTF8Encode(wsStr.GetPtr(), wsStr.GetLength());
839 } 843 }
840 inline CFX_ByteString FX_UTF8Encode(const CFX_WideString &wsStr) 844 inline CFX_ByteString FX_UTF8Encode(const CFX_WideString &wsStr)
841 { 845 {
842 return FX_UTF8Encode(wsStr.c_str(), wsStr.GetLength()); 846 return FX_UTF8Encode(wsStr.c_str(), wsStr.GetLength());
843 } 847 }
844 #endif 848 #endif
OLDNEW
« no previous file with comments | « no previous file | core/src/fpdfdoc/doc_bookmark.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698