Skip to content

Commit

Permalink
ReactTextView extends AppCompatTextView (#23321)
Browse files Browse the repository at this point in the history
Summary:
Google recommends to use AppCompat widgets, and this PR changes ReactTextView to extend AppCompatTextView.

[Android] [Changed] - ReactTextView extends AppCompatTextView
Pull Request resolved: #23321

Differential Revision: D13986149

Pulled By: cpojer

fbshipit-source-id: 878849fff12dc5478bb0d0952b2c22695391e81a
  • Loading branch information
dulmandakh authored and facebook-github-bot committed Feb 21, 2019
1 parent bca8510 commit ba0c3ff
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions ReactAndroid/src/main/java/com/facebook/react/views/text/BUCK
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ rn_android_library(
],
deps = [
YOGA_TARGET,
react_native_dep("third-party/android/support/v4:lib-support-v4"),
react_native_dep("third-party/android/support/v7/appcompat-orig:appcompat"),
react_native_dep("libraries/fbcore/src/main/java/com/facebook/common/logging:logging"),
react_native_dep("third-party/java/infer-annotations:infer-annotations"),
react_native_dep("third-party/java/jsr-305:jsr-305"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,21 @@
import android.content.Context;
import android.graphics.drawable.Drawable;
import android.os.Build;
import android.support.v7.widget.AppCompatTextView;
import android.text.Layout;
import android.text.Spannable;
import android.text.Spanned;
import android.text.TextUtils;
import android.view.Gravity;
import android.view.ViewGroup;
import android.widget.TextView;
import com.facebook.common.logging.FLog;
import com.facebook.react.common.ReactConstants;
import com.facebook.react.uimanager.ReactCompoundView;
import com.facebook.react.uimanager.ViewDefaults;
import com.facebook.react.views.view.ReactViewBackgroundManager;
import javax.annotation.Nullable;

public class ReactTextView extends TextView implements ReactCompoundView {
public class ReactTextView extends AppCompatTextView implements ReactCompoundView {

private static final ViewGroup.LayoutParams EMPTY_LAYOUT_PARAMS =
new ViewGroup.LayoutParams(0, 0);
Expand Down

0 comments on commit ba0c3ff

Please sign in to comment.