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

Unified Diff: Source/core/editing/SelectionStrategy.h

Issue 988023005: Implementing directional selection strategy in Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Putting GranularityStrategy into separate files. Created 5 years, 8 months 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/editing/SelectionStrategy.h
diff --git a/Source/core/css/resolver/AnimatedStyleBuilder.h b/Source/core/editing/SelectionStrategy.h
similarity index 80%
copy from Source/core/css/resolver/AnimatedStyleBuilder.h
copy to Source/core/editing/SelectionStrategy.h
index ff3110e022abd772f0f296022bf317ec0e516b97..d371f7cb84e97bbec4f8b88587c92950bd647df2 100644
--- a/Source/core/css/resolver/AnimatedStyleBuilder.h
+++ b/Source/core/editing/SelectionStrategy.h
@@ -1,5 +1,5 @@
/*
yosin_UTC9 2015/04/21 01:59:52 nit: Let's use the short version of licence commen
mfomitchev 2015/04/21 18:44:25 Done.
- * Copyright (C) 2013 Google Inc. All rights reserved.
+ * Copyright 2015, Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
@@ -28,21 +28,19 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef AnimatedStyleBuilder_h
-#define AnimatedStyleBuilder_h
-
-#include "core/CSSPropertyNames.h"
+#ifndef SelectionStrategy_h
+#define SelectionStrategy_h
namespace blink {
-class AnimatableValue;
-class StyleResolverState;
-
-class AnimatedStyleBuilder {
-public:
- static void applyProperty(CSSPropertyID, StyleResolverState&, const AnimatableValue*);
+enum SelectionStrategy {
yosin_UTC9 2015/04/21 01:59:52 nit: Let's use |enum class| for better type checki
mfomitchev 2015/04/21 18:44:25 Done.
+ // Always using CharacterGranularity
+ StrategyCharacter,
+ // Switches between WordGranularity and CharacterGranularity
+ // Depending on whether the selection or growing or shrinking
+ StrategyDirection,
};
} // namespace blink
-#endif // AnimatedStyleBuilder_h
+#endif // SelectionStrategy_h

Powered by Google App Engine
This is Rietveld 408576698