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

Side by Side Diff: fpdfsdk/src/pdfwindow/PWL_Utils.cpp

Issue 1512763013: Get rid of most instance of 'foo != NULL' (Closed) Base URL: https://pdfium.googlesource.com/pdfium@master
Patch Set: nits Created 5 years 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 | « fpdfsdk/src/pdfwindow/PWL_ScrollBar.cpp ('k') | fpdfsdk/src/pdfwindow/PWL_Wnd.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 #include "fpdfsdk/include/pdfwindow/PDFWindow.h" 7 #include "fpdfsdk/include/pdfwindow/PDFWindow.h"
8 #include "fpdfsdk/include/pdfwindow/PWL_Icon.h" 8 #include "fpdfsdk/include/pdfwindow/PWL_Icon.h"
9 #include "fpdfsdk/include/pdfwindow/PWL_Utils.h" 9 #include "fpdfsdk/include/pdfwindow/PWL_Utils.h"
10 #include "fpdfsdk/include/pdfwindow/PWL_Wnd.h" 10 #include "fpdfsdk/include/pdfwindow/PWL_Wnd.h"
(...skipping 510 matching lines...) Expand 10 before | Expand all | Expand 10 after
521 } 521 }
522 522
523 return sRet.GetByteString(); 523 return sRet.GetByteString();
524 } 524 }
525 525
526 CFX_ByteString CPWL_Utils::GetSpellCheckAppStream( 526 CFX_ByteString CPWL_Utils::GetSpellCheckAppStream(
527 IFX_Edit* pEdit, 527 IFX_Edit* pEdit,
528 IPWL_SpellCheck* pSpellCheck, 528 IPWL_SpellCheck* pSpellCheck,
529 const CPDF_Point& ptOffset, 529 const CPDF_Point& ptOffset,
530 const CPVT_WordRange* pRange) { 530 const CPVT_WordRange* pRange) {
531 ASSERT(pEdit != NULL);
532 ASSERT(pSpellCheck != NULL);
533
534 CFX_ByteTextBuf sRet; 531 CFX_ByteTextBuf sRet;
535 532
536 if (pRange && pRange->IsExist()) { 533 if (pRange && pRange->IsExist()) {
537 if (IFX_Edit_Iterator* pIterator = pEdit->GetIterator()) { 534 if (IFX_Edit_Iterator* pIterator = pEdit->GetIterator()) {
538 pIterator->SetAt(pRange->BeginPos); 535 pIterator->SetAt(pRange->BeginPos);
539 536
540 FX_BOOL bLatinWord = FALSE; 537 FX_BOOL bLatinWord = FALSE;
541 CPVT_WordPlace wpWordStart; 538 CPVT_WordPlace wpWordStart;
542 CFX_ByteString sWord; 539 CFX_ByteString sWord;
543 540
(...skipping 3160 matching lines...) Expand 10 before | Expand all | Expand 10 after
3704 break; 3701 break;
3705 case COLORTYPE_RGB: 3702 case COLORTYPE_RGB:
3706 CPWL_Utils::ConvertCMYK2RGB(fColor1, fColor2, fColor3, fColor4, 3703 CPWL_Utils::ConvertCMYK2RGB(fColor1, fColor2, fColor3, fColor4,
3707 fColor1, fColor2, fColor3); 3704 fColor1, fColor2, fColor3);
3708 break; 3705 break;
3709 } 3706 }
3710 break; 3707 break;
3711 } 3708 }
3712 nColorType = other_nColorType; 3709 nColorType = other_nColorType;
3713 } 3710 }
OLDNEW
« no previous file with comments | « fpdfsdk/src/pdfwindow/PWL_ScrollBar.cpp ('k') | fpdfsdk/src/pdfwindow/PWL_Wnd.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698