[GitHub] incubator-weex issue #1096: [iOS]fixed textfield menuController delete case ...
Github user Jsonmess commented on the issue: https://github.com/apache/incubator-weex/pull/1096 i am not implement UITextField "delete", because i think "delete" not useful. people have not behavior to use menu item "delete" to delete their input text. ---
[GitHub] incubator-weex issue #1096: fixed textfield menuController delete case crash
Github user weex-bot commented on the issue: https://github.com/apache/incubator-weex/pull/1096 Messages :book: has no jsfm file changed. :book: jsfm test finished. Generated by :no_entry_sign: http://github.com/danger/danger-js/";>dangerJS ---
[GitHub] incubator-weex pull request #1096: fixed textfield menuController delete cas...
GitHub user Jsonmess opened a pull request: https://github.com/apache/incubator-weex/pull/1096 fixed textfield menuController delete case crash First of all, thank you for your contribution! Please makes sure that these checkboxes are checked before submitting your PR, thank you! CheckList: **if** *isBugFix* **:** * [ ] Make sure that you add at least one unit test for the bug which you had fixed. **elif** *isNewFeature* **:** * [ ] Update API docs for the component. * [ ] Update/Add demo to demonstrate new feature. * [ ] Update test scripts for the feature. * [ ] Add unit tests for the feature. * [ios] fixed WXTextInputView MenuController menu item "unrecognized selector sent to instance" like "delete" in protocol "UIResponderStandardEditActions" You can merge this pull request into a Git repository by running: $ git pull https://github.com/Jsonmess/incubator-weex fixed-uitextfieldMenuIssue Alternatively you can review and apply these changes as the patch at: https://github.com/apache/incubator-weex/pull/1096.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1096 commit 28d34095dba860439b2e271e4c847befe97815b2 Author: zhutong Date: 2018-04-02T03:58:24Z fixed textfield menuController delete case crash ---
[GitHub] incubator-weex issue #1093: [WEEX-113] [iOS] New Touch Dispatch Mechanism An...
Github user doumafang commented on the issue: https://github.com/apache/incubator-weex/pull/1093 [WEEX-113] [iOS] New Touch Dispatch Mechanism And Bubble Sync Method ---
[GitHub] incubator-weex issue #1085: [Weex-260][android]switch supports setting color
Github user whn9527 commented on the issue: https://github.com/apache/incubator-weex/pull/1085 Thanks for reminding, I will pay attention next time ---
[GitHub] incubator-weex pull request #1085: [Weex-260][android]switch supports settin...
Github user asfgit closed the pull request at: https://github.com/apache/incubator-weex/pull/1085 ---
[1/2] incubator-weex git commit: + [android] switch component supports setting color
Repository: incubator-weex Updated Branches: refs/heads/master 808c818a0 -> 3222071d6 + [android] switch component supports setting color Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/8255eda6 Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/8255eda6 Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/8255eda6 Branch: refs/heads/master Commit: 8255eda611e80bb75048476c3743f52fc41f4213 Parents: f27bf04 Author: åéº Authored: Mon Mar 26 14:05:32 2018 +0800 Committer: åéº Committed: Mon Mar 26 14:05:32 2018 +0800 -- .../java/com/taobao/weex/common/Constants.java | 6 ++-- .../com/taobao/weex/ui/component/WXSwitch.java | 29 +++- .../com/taobao/weex/ui/view/WXSwitchView.java | 35 3 files changed, 67 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/8255eda6/android/sdk/src/main/java/com/taobao/weex/common/Constants.java -- diff --git a/android/sdk/src/main/java/com/taobao/weex/common/Constants.java b/android/sdk/src/main/java/com/taobao/weex/common/Constants.java index 4873f1f..e35fc65 100644 --- a/android/sdk/src/main/java/com/taobao/weex/common/Constants.java +++ b/android/sdk/src/main/java/com/taobao/weex/common/Constants.java @@ -207,8 +207,10 @@ public class Constants { String INCLUDE_FONT_PADDING = "includeFontPadding"; String ENABLE_COPY = "enableCopy"; - - +String THUMB_TINT_COLOR = "thumbTintColor"; +String ON_THUMB_TINT_COLOR = "onThumbTintColor"; +String TINT_COLOR = "tintColor"; +String ON_TINT_COLOR = "onTintColor"; interface Recycler{ String LIST_DATA = "listData"; http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/8255eda6/android/sdk/src/main/java/com/taobao/weex/ui/component/WXSwitch.java -- diff --git a/android/sdk/src/main/java/com/taobao/weex/ui/component/WXSwitch.java b/android/sdk/src/main/java/com/taobao/weex/ui/component/WXSwitch.java index 7893440..27e4c95 100644 --- a/android/sdk/src/main/java/com/taobao/weex/ui/component/WXSwitch.java +++ b/android/sdk/src/main/java/com/taobao/weex/ui/component/WXSwitch.java @@ -23,7 +23,6 @@ import android.support.annotation.NonNull; import android.widget.CompoundButton; import com.taobao.weex.WXSDKInstance; -import com.taobao.weex.WXSDKManager; import com.taobao.weex.annotation.Component; import com.taobao.weex.common.Constants; import com.taobao.weex.dom.WXDomObject; @@ -38,6 +37,10 @@ import java.util.Map; public class WXSwitch extends WXComponent { private CompoundButton.OnCheckedChangeListener mListener; + private String mTrackTintColorNormal; + private String mTrackTintColorActivated; + private String mThumbTintColorNormal; + private String mThumbTintColorActivated; @Deprecated public WXSwitch(WXSDKInstance instance, WXDomObject dom, WXVContainer parent, String instanceId, boolean isLazy) { @@ -94,6 +97,22 @@ public class WXSwitch extends WXComponent { setChecked(result); } return true; + case Constants.Name.THUMB_TINT_COLOR: +mThumbTintColorNormal = WXUtils.getString(param, null); +setThumbColor(); +return true; + case Constants.Name.ON_THUMB_TINT_COLOR: +mThumbTintColorActivated = WXUtils.getString(param, null); +setThumbColor(); +return true; + case Constants.Name.TINT_COLOR: +mTrackTintColorNormal = WXUtils.getString(param, null); +setTrackColor(); +return true; + case Constants.Name.ON_TINT_COLOR: +mTrackTintColorActivated = WXUtils.getString(param, null); +setTrackColor(); +return true; } return super.setProperty(key, param); } @@ -104,4 +123,12 @@ public class WXSwitch extends WXComponent { getHostView().setChecked(checked); getHostView().setOnCheckedChangeListener(mListener); } + + private void setThumbColor() { +getHostView().setThumbColor(mThumbTintColorNormal, mThumbTintColorActivated); + } + + private void setTrackColor() { +getHostView().setTrackColor(mTrackTintColorNormal, mTrackTintColorActivated); + } } http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/8255eda6/android/sdk/src/main/java/com/taobao/weex/ui/view/WXSwitchView.java -- diff --git a/android/sdk/src/main/java/com/taobao/weex/ui/view/WXSwitchView.java b/android/sdk/src/main/java/com/taobao/weex/ui/view/WXSwitchView.java index fc96a7d..9568b23 100644 --- a/android/sdk/src/main/java/com/taobao/weex/ui/view/WXSwitchView.java +++ b/android/sdk/src/main
[2/2] incubator-weex git commit: Merge branch 'android-feature-switch' of https://github.com/whn9527/incubator-weex into merge-pull-request-master
Merge branch 'android-feature-switch' of https://github.com/whn9527/incubator-weex into merge-pull-request-master Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/3222071d Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/3222071d Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/3222071d Branch: refs/heads/master Commit: 3222071d6e2e37c6b21a22f6fc14eb711f528be9 Parents: 808c818 8255eda Author: acton393 Authored: Sun Apr 1 21:15:12 2018 +0800 Committer: acton393 Committed: Sun Apr 1 21:15:12 2018 +0800 -- .../java/com/taobao/weex/common/Constants.java | 6 ++-- .../com/taobao/weex/ui/component/WXSwitch.java | 29 +++- .../com/taobao/weex/ui/view/WXSwitchView.java | 35 3 files changed, 67 insertions(+), 3 deletions(-) --
[GitHub] incubator-weex issue #1085: [Weex-260][android]switch supports setting color
Github user acton393 commented on the issue: https://github.com/apache/incubator-weex/pull/1085 hi @whn9527 maybe your commit message should be the format like ``` [WEEX-jira][iOS/Android] summary description Bug/ImprovementId(jira ID) ``` not just like `*[Android]` later thanks ---
[GitHub] incubator-weex pull request #1095: [WEEX-270][iOS]WXListComponent should add...
Github user asfgit closed the pull request at: https://github.com/apache/incubator-weex/pull/1095 ---
[1/4] incubator-weex git commit: [WEEX-270][iOS]WXListComponent should add reload type of data update
Repository: incubator-weex Updated Branches: refs/heads/master 28d776877 -> 808c818a0 [WEEX-270][iOS]WXListComponent should add reload type of data update Currently WXListComponent data update only supports insertRows. This can't be satisfied under some drop-down loading scenes. For example, the pulldown load needs to be positioned to the original position. When the tableView is still decaling and inserts and tries to fix the position, the cell will blink. Because when deceiring, the externally modified contentOffset will be re-edited by the internal implementation of tableView, altering contentOffset alternately will cause flicker problems. If you use the tableView reloadData this is not a problem, so you need to support the WXListComponent in the drop-down restore location scene to add the reload attribute. featï¼270 Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/9f75e24e Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/9f75e24e Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/9f75e24e Branch: refs/heads/master Commit: 9f75e24ef14810d5a0fa47b8c10fe7018b35ffc5 Parents: 0bc243d Author: jianjun.mjj Authored: Fri Mar 30 09:55:52 2018 +0800 Committer: jianjun.mjj Committed: Fri Mar 30 09:55:52 2018 +0800 -- ios/sdk/WeexSDK/Sources/Component/WXListComponent.m | 14 -- 1 file changed, 12 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/9f75e24e/ios/sdk/WeexSDK/Sources/Component/WXListComponent.m -- diff --git a/ios/sdk/WeexSDK/Sources/Component/WXListComponent.m b/ios/sdk/WeexSDK/Sources/Component/WXListComponent.m index cdf4be2..159f0a4 100644 --- a/ios/sdk/WeexSDK/Sources/Component/WXListComponent.m +++ b/ios/sdk/WeexSDK/Sources/Component/WXListComponent.m @@ -119,6 +119,8 @@ // Only accessed on main thread NSMutableArray *_completedSections; NSUInteger _previousLoadMoreRowNumber; +// insert & reload & batch +NSString *_updataType; BOOL _isUpdating; NSMutableArray *_updates; @@ -131,6 +133,7 @@ _sections = [NSMutableArray array]; _completedSections = [NSMutableArray array]; _reloadInterval = attributes[@"reloadInterval"] ? [WXConvert CGFloat:attributes[@"reloadInterval"]]/1000 : 0; +_updataType = [WXConvert NSString:attributes[@"updataType"]]?:@"insert"; [self fixFlicker]; } @@ -182,6 +185,9 @@ if (attributes[@"reloadInterval"]) { _reloadInterval = [WXConvert CGFloat:attributes[@"reloadInterval"]] / 1000; } +if (attributes[@"updataType"]) { +_updataType = [WXConvert NSString:attributes[@"updataType"]]; +} } - (void)setContentSize:(CGSize)contentSize @@ -899,9 +905,13 @@ - (void)_insertTableViewCellAtIndexPath:(NSIndexPath *)indexPath keepScrollPosition:(BOOL)keepScrollPosition animation:(UITableViewRowAnimation)animation { [self _performUpdates:^{ -[_tableView insertRowsAtIndexPaths:[NSArray arrayWithObject:indexPath] withRowAnimation:animation]; +if ([_updataType isEqual: @"reload"]) { +[_tableView reloadData]; +} else { +[_tableView insertRowsAtIndexPaths:[NSArray arrayWithObject:indexPath] withRowAnimation:animation]; +} } withKeepScrollPosition:keepScrollPosition adjustmentBlock:^CGFloat(NSIndexPath *top) { -if ([indexPath compare:top] <= 0) { +if (([indexPath compare:top] <= 0) || [_updataType isEqual: @"reload"]) { return [self tableView:_tableView heightForRowAtIndexPath:indexPath]; } else { return 0.0;
[3/4] incubator-weex git commit: Merge branch 'im_drop_down' of https://github.com/bbmjja8123/incubator-weex into merge-pull-request-master
Merge branch 'im_drop_down' of https://github.com/bbmjja8123/incubator-weex into merge-pull-request-master Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/939bb19f Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/939bb19f Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/939bb19f Branch: refs/heads/master Commit: 939bb19f7e48332de006de3f6401ee8bbbce412a Parents: 069fea2 c192766 Author: acton393 Authored: Sun Apr 1 21:08:23 2018 +0800 Committer: acton393 Committed: Sun Apr 1 21:08:23 2018 +0800 -- .../WeexSDK/Sources/Component/WXListComponent.m | 14 +- .../Sources/Component/WXRefreshComponent.h | 2 + .../Sources/Component/WXRefreshComponent.m | 41 --- .../Sources/Component/WXScrollerComponent.m | 53 +++- .../Sources/Protocol/WXScrollerProtocol.h | 1 + 5 files changed, 100 insertions(+), 11 deletions(-) --
[2/4] incubator-weex git commit: [WEEX-271][iOS]Extend the pulldown WXRefreshComponent to support immediate load of the appear
[WEEX-271][iOS]Extend the pulldown WXRefreshComponent to support immediate load of the appear WXRefreshComponent current only support the â¡, shuold add new type ofâ . // â refreshForAppear: load more when refresh component begin appear(if scroll is dragging or decelerating, should delay) // â¡refreshForWholeVisible: load more until the whole refresh component visible NSString *_refreshType; Improvementï¼271 Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/c1927668 Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/c1927668 Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/c1927668 Branch: refs/heads/master Commit: c1927668c72a81981ecf8dcb3046b4237fd8bc86 Parents: 9f75e24 Author: bbmjja8123 Authored: Fri Mar 30 10:27:05 2018 +0800 Committer: bbmjja8123 Committed: Fri Mar 30 10:27:05 2018 +0800 -- .../Sources/Component/WXRefreshComponent.h | 2 + .../Sources/Component/WXRefreshComponent.m | 41 --- .../Sources/Component/WXScrollerComponent.m | 53 +++- .../Sources/Protocol/WXScrollerProtocol.h | 1 + 4 files changed, 88 insertions(+), 9 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/c1927668/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.h -- diff --git a/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.h b/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.h index a2c2b31..5fabfec 100644 --- a/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.h +++ b/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.h @@ -31,4 +31,6 @@ - (void)pullingdown:(NSDictionary*)param; +- (void)setIndicatorHidden:(BOOL)hidden; + @end http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/c1927668/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.m -- diff --git a/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.m b/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.m index 67d2602..99876f4 100644 --- a/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.m +++ b/ios/sdk/WeexSDK/Sources/Component/WXRefreshComponent.m @@ -148,15 +148,33 @@ if (scrollerProtocol == nil || !_initFinished) return; -CGPoint offset = [scrollerProtocol contentOffset]; -if (_displayState) { -offset.y = -self.calculatedFrame.size.height; -[_indicator start]; +if ([scrollerProtocol respondsToSelector:@selector(refreshType)] && +[[scrollerProtocol refreshType] isEqualToString:@"refreshForAppear"]) { +UIEdgeInsets inset = [scrollerProtocol contentInset]; +inset.top = self.calculatedFrame.size.height; +if (_displayState) { +if ([_indicator.view isHidden]) { +[_indicator.view setHidden:NO]; +} +[_indicator start]; +} else { +[_indicator stop]; +} +[scrollerProtocol setContentInset:inset]; } else { -offset.y = 0; -[_indicator stop]; +CGPoint offset = [scrollerProtocol contentOffset]; +if (_displayState) { +offset.y = -self.calculatedFrame.size.height; +if ([_indicator.view isHidden]) { +[_indicator.view setHidden:NO]; +} +[_indicator start]; +} else { +offset.y = 0; +[_indicator stop]; +} +[scrollerProtocol setContentOffset:offset animated:YES]; } -[scrollerProtocol setContentOffset:offset animated:YES]; } @@ -165,4 +183,13 @@ return _displayState; } +- (void)setIndicatorHidden:(BOOL)hidden { +[_indicator.view setHidden:hidden]; +if (!hidden) { +[_indicator start]; +} else { +[_indicator stop]; +} +} + @end http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/c1927668/ios/sdk/WeexSDK/Sources/Component/WXScrollerComponent.m -- diff --git a/ios/sdk/WeexSDK/Sources/Component/WXScrollerComponent.m b/ios/sdk/WeexSDK/Sources/Component/WXScrollerComponent.m index b0c8dae..c6f13a1 100644 --- a/ios/sdk/WeexSDK/Sources/Component/WXScrollerComponent.m +++ b/ios/sdk/WeexSDK/Sources/Component/WXScrollerComponent.m @@ -72,6 +72,10 @@ BOOL _scrollable; NSString * _alwaysScrollableVertical; NSString * _alwaysScrollableHorizontal; + +// refreshForAppear: load more when refresh component begin appear(if scroll is dragging or decelerating, should delay) +// refreshForWholeVisible: load more until the whole refresh component visible +NSString *_refreshType; // vertical & horizontal
[4/4] incubator-weex git commit: Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/incubator-weex into merge-pull-request-master
Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/incubator-weex into merge-pull-request-master Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/808c818a Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/808c818a Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/808c818a Branch: refs/heads/master Commit: 808c818a003a3317b140f90180df8a8c3a661818 Parents: 939bb19 28d7768 Author: acton393 Authored: Sun Apr 1 21:08:49 2018 +0800 Committer: acton393 Committed: Sun Apr 1 21:08:49 2018 +0800 -- android/playground/app/build.gradle | 4 ++-- android/sdk/build.gradle| 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) --
[GitHub] incubator-weex issue #1095: [WEEX-270][iOS]WXListComponent should add reload...
Github user acton393 commented on the issue: https://github.com/apache/incubator-weex/pull/1095 thank you for your contribution that bring improvement for Weex ---