HTML and Flex Focus Problem - html

I have a web page which has a SWF file embeded. I have an issue with the focus.
Click on a HTML Text Field and Click on a Flex Field.
Begin to type a text.
Expected Result is the entered text should go in the Flex TextInput field but the
actual Result is it goes into HTML text field.

to me it sounds like something related to wmode in the embedding code, I would try to play around with that, I have found flash to be very problematic when replacing between wmodes.

Related

Why is Angular mat-form-field textarea is blinking while typing?

I am using Angular 12 and I have a dialog which contains a form. A the very bottom of the form there is a mat-form-field that contains a textarea. Sometimes (not always) when I open the model and type in the text area the text begins to blink/ flash between the current and previous row. See gif below. I haven't been able to reproduce the problem in stackblitz or anything so I'm not sure what to provide for a mwe.

How can I get the markup's core extension to automatically close the text area it creates?

The MarkupsCore extension automatically creates a text area when you click that you enter text into. Now, I automatically insert text into this text area, but cannot find out how to close it programatically. After going through the source a little bit, it seemed like the text area was a little bit custom as I saw there were some custom implementations of the backspace button, etc. So, I assumed there was a different event.
It seems to happen when you focus out of the element, but that event didn't seem to do it either. In version 3 (or maybe it was earlier, I can't remember), you used to press the enter key. Now you just focus out.
So, what event needs to be fired in order to tell the extension to close the text area and create the markup?
Try the following...
Using the 'markupscore' object, send a 'mouse down' event with 'target:null' like this...
markupscoreExt = viewer.getExtension("Autodesk.Viewing.MarkupsCore")
markupscoreExt.onMouseDown({target:null})
As you are in the middle of typing some text, you can trigger the mouse down event to complete the text.
Let me know if that helps.
Cheers
Michael

ADF RichTextEditor autosubmit doesn't work in Google Chrome

I'm facing a problem when using the RichTextEditor with autosubmit="true" in JDev 12c. The component is added programmatically on a form.
In Firefox the autosubmit fires correctly for any  kind of action (e.g.: typing, changing text style, etc)
On the other side in Chrome, not every action fires the autosubmit. For example, typing some text would fire the autosubmit, but then selecting the text and changing the color or the font size for example, doesn't fire a value change event / autosubmit.
Has anyone else encountered this type of behavior before?
Thanks in advance!
I had the same problem as well, RichTextEditor's text is very difficult to erase the content or reset programatically too,
I advise to use other text tools like the very known RichTextArea:
// Create a rich text area
final RichTextArea rtArea = new RichTextArea();
rtArea .setCaption("My Rich Text Area");
// Set initial content as HTML
rtArea .setValue("<h1>Hello</h1>\n" +
"<p>This rich text area contains some text.</p>");
Then you could resize it to the size of the RichTextEditor and give it the same visual color by some tricks through js and css as usual.

Losing focus on TLF Text

I have embedded my SWF file to an HTML. I am using a TLF text in my AS3 application for the chatbox, but the problem is that the application loses its focus on TLF text while I switch to other pages, and switch back on my application. Please note that I do not face this problem while I run the SWF file using flash player on my desktop.
I have tried to use following code to re-focus on the TLF text but it does not work on my case.
addEventListener(Event.ACTIVATE, infocus);
function infocus(e:Event):void {
myTLF.textFlow.interactionManager = new EditManager();
myTLF.textFlow.interactionManager.selectRange(myTLF.text.length, myTLF.text.length);
myTLF.textFlow.interactionManager.setFocus();
}
My question is how we can resolve this? because it really bothers people since they have to click on the chatbox every times that they switch to other pages.
There are few ways to do so. You can manually put focus on your desired objects either by:
listening to MouseEvent.ROLL_OVER on your stage make a handler that will return the focus to your text field
if you want to make it to return focus on switch back to the page, you'll need to write a JS script that will tell SWF via ExternalInterface to put focus on your text field.

Flex Textfield doesnot gain focus when cursor is in text field of iframe

I have a web page which has a SWF file embeded. I have an issue with the focus.
Steps to reproduce:
1)Click on a HTML Text Field which is inside a Iframe
2)Click on a Flex Field.
3)Begin to type some text.
Expected Result is the entered text should go in the Flex TextInput field but the actual Result is it goes into HTML text field.
This is the bug which was filed but closed without any resolution. The workaround suggested there doesnt work. ( bugs.adobe.com/jira/browse/SDK-12377 )
This is happening only in IE 6.0 and IE 7.0. Below is the live example.
http://drumbeatinsight.com/examples/htmlcomponent/iframe/HTMLFrameInApplication.html
Any Suggestions or workaround to solve this problem are requested.
Your browser is maintaining focus instead of giving it back to the flash player. I ran into this issue when trying to 'embed' html content inside my flex app ... accomplished by floating html iframe above the flash player.
I have to hide and restore the iframe if I want to interact with flex because the iframe needs to be on top of the flash player, but all that is easy. I would find, even if I hid the iframe, flash player was never getting keyboard focus back. You need to tell the browser to give keyboard focus back to the flash player.
Now there is no really good way to determine if you need to instruct the browser to give keyboard focus back, I end up executing this javascript on every mouse down, rather inefficient, but it was the only way to gaurentee whenever my user clicked on flash player content, that the browser gave keyboard focus back.
Execute a javascript method that looks up the embeded content by name and call focus().
Basically - document.getElementById('flexEmbedID').focus();
Use the external interface to call that on stage.mouseDown(). Lots of overhead as it executes a lot, but it will fix your problem.