Giter Site home page Giter Site logo

rundo's People

Contributors

ppartisan avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

rundo's Issues

Fatal Exception: java.lang.StringIndexOutOfBoundsException

Im getting Fatal Exception: java.lang.StringIndexOutOfBoundsException

my logs :
java.lang.String.substring (String.java:1931)
com.werdpressed.partisan.rundo.SubtractStrings.getReplacedText (Unknown Source)
com.werdpressed.partisan.rundo.SubtractStrings.getItem (Unknown Source)
com.werdpressed.partisan.rundo.WriteToArrayDequeRunnable.run (Unknown Source)
android.os.Handler.handleCallback (Handler.java:751)
android.os.Handler.dispatchMessage (Handler.java:95)
android.os.Looper.loop (Looper.java:154)
android.app.ActivityThread.main (ActivityThread.java:6682)
java.lang.reflect.Method.invoke (Method.java)
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:1534)
com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1424)

Im running version : 1.0.5

After rotation (on resume), undo and redo are not working

Prerequisites:

I have an activity with a fragmentPager and fragments, compiled against SDK28.
But i assume the bug could be reproduced with every activity using RunDo.

Description

Change the text of the linked EditText. Then rotate the device. The activity and thus RunDo(Support) get rebuild. But RunDo is in a broken state: neither undo nor redo will work. Even when changing the linked EditText's text again.

I think the bug is happening on this line:

RunDo gets instantiated with TRACKING_ENDED, what would work fine.

public RunDoSupport() {
mHandler = new Handler();
mRunnable = new WriteToArrayDequeRunnable(this);
countdownTimerLength = DEFAULT_TIMER_LENGTH;
queueSize = DEFAULT_QUEUE_SIZE;
trackingState = TRACKING_ENDED;
}

But when resuming, it is set on TRACKING_STARTED, leaving RunDo in a somewhat illegal state.

Get queue size

How can I get queue size? I want to use it to disable the undo and redo buttons when queue is empty.

Use on view extending EditText

How can I use this on my view which extends EditText? I can't return EditText on getEditText() method because it isn't one.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.