WordPress.org

Ready to get started?Download WordPress

Forums

Editorial Calendar
[resolved] Overly zealous capturing of enter key hard for Japanese input (3 posts)

  1. mehori
    Member
    Posted 1 year ago #

    OK, this needs a little explanation, please bear with me :-)

    When we enter Japanese text, we use input methods to convert our keystrokes into Chinese characters. This is usually done by 1. start entering the text, 2. press shift and select the character you want, 3. press ENTER to finalize the conversion, and repeat 1-3 until you can input the whole text.

    There is a problem when we try to do this in the pop-up window creating new posts from the calendar. The pop-up receives the first ENTER keystroke and go ahead to create a post even though I am not finished with the text. This makes Editorial Calendar very tricky if not impossible to use with a Japanese input method.

    Is there a way so that the pop-up would not close until I click the save button manually?

    I have tested this behavior on OSX 10.8.4 using the latest version of Chrome, Safari and Firefox.

    http://wordpress.org/extend/plugins/editorial-calendar/

  2. Zack Grossbart
    Member
    Plugin Author

    Posted 1 year ago #

    You could make a small code change to make this happen. In edcal.js on line 422 it looks like this:

    if (evt.keyCode === 13) { // enter key
    /*
    * If the user presses enter we want to save the draft.
    */
    return edcal.savePost(null, true);
    }

    Just comment out the return and won't save the post when you press enter. You'll also need to add &dev=true to the URL to see your changes.

    Good luck,
    Zack

  3. mehori
    Member
    Posted 1 year ago #

    First I edited edcal.js directly and nothing happened, but I quickly noticed that there is a edcal.min.js file and deleted the corresponding portion. It worked like a charm.

    I'll make a blog post for my fellow Japanese readers.
    Thank you!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic