Change the forced clear order of CPDF_DocPageData::Clear, and remove m_pDocument...
authorBo Xu <bo_xu@foxitsoftware.com>
Wed, 10 Sep 2014 01:39:30 +0000 (18:39 -0700)
committerBo Xu <bo_xu@foxitsoftware.com>
Wed, 10 Sep 2014 01:39:30 +0000 (18:39 -0700)
commit9175beec2686231fe284e8c8095d04668817509b
treee8956fbb7dd070c405a4586ca54b69d6c2caf6ef
parent663af999d721f86e828a87354c380b76d146cedf
Change the forced clear order of CPDF_DocPageData::Clear, and remove m_pDocument in CPDF_Color

If not forced clear, the counter of CPDF_Pattern will take care the count of referenced instance.
When forced clear, clear color first to make sure pattern still exists when referencing it.

BUG=411154
R=tsepez@chromium.org

Review URL: https://codereview.chromium.org/554913003
core/include/fpdfapi/fpdf_resource.h
core/src/fpdfapi/fpdf_page/fpdf_page_colors.cpp
core/src/fpdfapi/fpdf_page/fpdf_page_doc.cpp