| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 The Chromium 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 #include "chrome/common/gfx/emf.h" | 5 #include "chrome/common/gfx/emf.h" |
| 6 | 6 |
| 7 // For quick access. | 7 // For quick access. |
| 8 #include <wingdi.h> | 8 #include <wingdi.h> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/file_util.h" | 11 #include "base/file_util.h" |
| 12 #include "base/logging.h" | |
| 13 #include "base/path_service.h" | 12 #include "base/path_service.h" |
| 14 #include "chrome/browser/printing/win_printing_context.h" | 13 #include "chrome/browser/printing/win_printing_context.h" |
| 15 #include "chrome/common/chrome_paths.h" | 14 #include "chrome/common/chrome_paths.h" |
| 16 #include "testing/gtest/include/gtest/gtest.h" | 15 #include "testing/gtest/include/gtest/gtest.h" |
| 17 | 16 |
| 18 namespace { | 17 namespace { |
| 19 | 18 |
| 20 // This test is automatically disabled if no printer named "UnitTest Printer" is | 19 // This test is automatically disabled if no printer named "UnitTest Printer" is |
| 21 // available. | 20 // available. |
| 22 class EmfPrintingTest : public testing::Test { | 21 class EmfPrintingTest : public testing::Test { |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 106 ptrdiff_t index = itr - emf_enum.begin(); | 105 ptrdiff_t index = itr - emf_enum.begin(); |
| 107 // If you get this assert, you need to lookup iType in wingdi.h. It starts | 106 // If you get this assert, you need to lookup iType in wingdi.h. It starts |
| 108 // with EMR_HEADER. | 107 // with EMR_HEADER. |
| 109 EMR_HEADER; | 108 EMR_HEADER; |
| 110 EXPECT_TRUE(itr->SafePlayback(NULL)) << | 109 EXPECT_TRUE(itr->SafePlayback(NULL)) << |
| 111 " index: " << index << " type: " << itr->record()->iType; | 110 " index: " << index << " type: " << itr->record()->iType; |
| 112 } | 111 } |
| 113 context.PageDone(); | 112 context.PageDone(); |
| 114 context.DocumentDone(); | 113 context.DocumentDone(); |
| 115 } | 114 } |
| OLD | NEW |