@Desmanto, because it log all type of event, not only the type we choosing. You should try to see the event type.
text matching is not triggered
Moderator: Martin
Re: text matching is not triggered
Re: text matching is not triggered
Yes, it show everything. i purposely reimport the flow several time and immediately check the recent events (less than 2 seconds). It shows various event, including Window openend. But none contain the wording "Flow already exists". So i guess we can't detect it if the window title doesn't give unique naming. As Window title "Flow" is too generic inside Automagic.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Re: text matching is not triggered
Just use this text you found:Desmanto wrote: ↑13 May 2020 18:10Yes, it show everything. i purposely reimport the flow several time and immediately check the recent events (less than 2 seconds). It shows various event, including Window openend. But none contain the wording "Flow already exists". So i guess we can't detect it if the window title doesn't give unique naming. As Window title "Flow" is too generic inside Automagic.
Code: Select all
Flow
- Option
- matches glob
- matches regex
Re: text matching is not triggered
In that case, it seems misleading. Clearly the assumption based on the UI event > window opened trigger is that it uses the text in the window title, not the window's label. Even the help screen says "Window opened...variable text often contains the title of the window." To me and Desmanto, and I would assume many/most others, that would indicate that it's looking at the text in the window's title, not some behind-the-scenes label. So if that's not the case, a) it's misleading and should be reworded to be more clear, b) there should be a variable for the actual text in the window, and c) how do we get the window's label, since it isn't shown?
Re: text matching is not triggered
@Hit : With keyword "Flow", it triggers at every flow opening, flow options and flow import. While it is not at all Automagic's windows, we still need to filter the result to show only flow import; which happen less frequently than others. Making the trigger have more false branch execution that the useful true branch one. It is usable, but create more overhead. It will be last solution if no other option available.
@vertigo : It is we misunderstand it.
a. Maybe Automagic still can make it clearer by labelling the Text as Window Title's Text.
b. To get the text on the active window, use CUI getTextInActiveWindow().
c. you can get the window title by using Recent events. Automagic already log the recent UI Event. You can also use debug dialog, check the variable text. Or you can log the whole trigger using my variable logger flow.
@vertigo : It is we misunderstand it.
a. Maybe Automagic still can make it clearer by labelling the Text as Window Title's Text.
b. To get the text on the active window, use CUI getTextInActiveWindow().
c. you can get the window title by using Recent events. Automagic already log the recent UI Event. You can also use debug dialog, check the variable text. Or you can log the whole trigger using my variable logger flow.
Index of Automagic useful thread List of my other useful posts (and others')
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Xiaomi Redmi Note 5 (whyred), AOSP Extended v6.7 build 20200310 Official, Android Pie 9.0, Rooted.
Re: text matching is not triggered
I haven't don't really know the problem that you have but you can try another approach. Hope you find better solution.
Re: text matching is not triggered
Even that won't work. In my testing, the UI event triggers repeatedly just by having a flow, any flow, open. It seems almost every Automagic window has text="Flow" and the event type "Window opened" acts more like "Window open," i.e. triggered by a window with the specified text being open, not by the action of opening it.Desmanto wrote: ↑14 May 2020 10:12With keyword "Flow", it triggers at every flow opening, flow options and flow import. While it is not at all Automagic's windows, we still need to filter the result to show only flow import; which happen less frequently than others. Making the trigger have more false branch execution that the useful true branch one. It is usable, but create more overhead. It will be last solution if no other option available.
I'm not seeing any way of accomplishing this. I thought if there was a way to trigger when opening an xml file with Automagic that could work, but AFAICT there's not. Definitely up against a wall on this one.
Re: text matching is not triggered
Hi vertigo
What do you want to achieve? Are you seeking help for component clicked or window opened trigger? If component clicked here is an example
Trigger = ui event (component clicked)
select package name and Leave text field Empty
Condition = Use expression as below
From record4
What do you want to achieve? Are you seeking help for component clicked or window opened trigger? If component clicked here is an example
Trigger = ui event (component clicked)
select package name and Leave text field Empty
Condition = Use expression as below
From record4
Code: Select all
text_list = newList("Expansion","Lock","Store","Flows","Ui infos");
for (i in text_list)
{
if (matches(i,text))
return true
}
return false
No.1 Automation app in play store Automagic Premium
Samsung Galaxy j2 non rooted.
Android 5.1.1
Samsung Galaxy j2 non rooted.
Android 5.1.1
Re: text matching is not triggered
I'm trying to make a flow for importing flows when one already exists with the name of the imported one. Currently, Automagic just tells you one already exists then leaves it up to you to rename or delete that flow then go back and import the new one again. It's discussed in this thread. The problem is, the only way to trigger a flow to do this automatically would be to use the UI event "Window opened" but there's no way to specify the "Flow already exists" window that shows when trying to import a flow, since just about every screen in Automagic has the "text" variable "Flow," which seems to be a bug.
Re: text matching is not triggered
Isn't it have an option Replace existing?