Skip to content
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.

Fix behavior themes in Google Chrome #2

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Evertt
Copy link

@Evertt Evertt commented Jul 17, 2014

When I used the ace element in Chrome the themes wouldn't behave well. Whenever I changed the theme or re-initialized the ace-element then all styles on the editor would disappear. This fixes that problem.

I didn't fix this problem myself, credits go to nightwing who helped me here

In Chrome themes wouldn't behave well, styles would disappear whenever the theme changed or whenever the editor was re-initialized. This fixes that problem.
@Evertt
Copy link
Author

Evertt commented Jul 17, 2014

I signed the CLA just now by the way.

@Evertt
Copy link
Author

Evertt commented Jul 17, 2014

How's that?

@Evertt Evertt added cla: yes and removed cla: no labels Jul 21, 2014
@@ -59,6 +59,24 @@
// this.editor is not set, we create a dummy editor. At editor
// initialization time, any pending changes are synch'd.
ready: function() {
ace.require("ace/lib/dom").importCssString = function(cssText, id) {
if (this.styles[id]) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried this fix in Atom Shell (Chromium) and I get an exception here if I don't initialise this.styles.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants