diff options
author | Kohei Yoshida <kohei.yoshida@collabora.com> | 2013-10-19 21:07:26 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@collabora.com> | 2013-10-20 13:44:42 -0400 |
commit | 73353186d58ae187f3f1ce4f206795424fb3336c (patch) | |
tree | 0ead8d1f7ac4ba520212496e7b619f0425bd104b /sc/inc/compare.hxx | |
parent | 7b7a73d05be7e5409013dde7bd82909f2a5e3efe (diff) |
Better way to organize 2 compared cell values.
Turns out this is slightly faster too.
Change-Id: I5a8c3474ab2a342200a5cfa9a93e6d89433595c4
Diffstat (limited to 'sc/inc/compare.hxx')
-rw-r--r-- | sc/inc/compare.hxx | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/sc/inc/compare.hxx b/sc/inc/compare.hxx index 0bbf8dcc45fd..3189bc81d05a 100644 --- a/sc/inc/compare.hxx +++ b/sc/inc/compare.hxx @@ -30,23 +30,23 @@ namespace sc { struct Compare { - double nVal[2]; - OUString* pVal[2]; - bool bVal[2]; - bool bEmpty[2]; + struct Cell + { + double mfValue; + OUString* mpStr; + bool mbValue; + bool mbEmpty; + + Cell(); + Cell( OUString* p ); + }; + + Cell maCells[2]; ScQueryOp meOp; bool mbIgnoreCase; - Compare( OUString* p1, OUString* p2 ) : - meOp(SC_EQUAL), - mbIgnoreCase(true) - { - pVal[0] = p1; - pVal[1] = p2; - bEmpty[0] = false; - bEmpty[1] = false; - } + Compare( OUString* p1, OUString* p2 ); }; struct CompareOptions |