| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 | 40 |
| 41 namespace blink { | 41 namespace blink { |
| 42 | 42 |
| 43 // Recommended maximum size for both explicit and implicit grids. Note that this | 43 // Recommended maximum size for both explicit and implicit grids. Note that this |
| 44 // actually allows a [-9999,9999] range. The limit is low on purpouse because | 44 // actually allows a [-9999,9999] range. The limit is low on purpouse because |
| 45 // higher values easly trigger OOM situations. That will definitely improve once | 45 // higher values easly trigger OOM situations. That will definitely improve once |
| 46 // we switch from a vector of vectors based grid representation to a more | 46 // we switch from a vector of vectors based grid representation to a more |
| 47 // efficient one memory-wise. | 47 // efficient one memory-wise. |
| 48 const int kGridMaxTracks = 1000; | 48 const int kGridMaxTracks = 1000; |
| 49 | 49 |
| 50 // A span in a single direction (either rows or columns). Note that |startLine| | 50 // A span in a single direction (either rows or columns). Note that |start_line| |
| 51 // and |endLine| are grid lines' indexes. | 51 // and |end_line| are grid lines' indexes. |
| 52 // Despite line numbers in the spec start in "1", the indexes here start in "0". | 52 // Despite line numbers in the spec start in "1", the indexes here start in "0". |
| 53 struct GridSpan { | 53 struct GridSpan { |
| 54 USING_FAST_MALLOC(GridSpan); | 54 USING_FAST_MALLOC(GridSpan); |
| 55 | 55 |
| 56 public: | 56 public: |
| 57 static GridSpan UntranslatedDefiniteGridSpan(int start_line, int end_line) { | 57 static GridSpan UntranslatedDefiniteGridSpan(int start_line, int end_line) { |
| 58 return GridSpan(start_line, end_line, kUntranslatedDefinite); | 58 return GridSpan(start_line, end_line, kUntranslatedDefinite); |
| 59 } | 59 } |
| 60 | 60 |
| 61 static GridSpan TranslatedDefiniteGridSpan(size_t start_line, | 61 static GridSpan TranslatedDefiniteGridSpan(size_t start_line, |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 176 | 176 |
| 177 GridSpan columns; | 177 GridSpan columns; |
| 178 GridSpan rows; | 178 GridSpan rows; |
| 179 }; | 179 }; |
| 180 | 180 |
| 181 typedef HashMap<String, GridArea> NamedGridAreaMap; | 181 typedef HashMap<String, GridArea> NamedGridAreaMap; |
| 182 | 182 |
| 183 } // namespace blink | 183 } // namespace blink |
| 184 | 184 |
| 185 #endif // GridArea_h | 185 #endif // GridArea_h |
| OLD | NEW |