Flex 4: Changing the “displayAsPassword” default character
Today I ran into a situation where I wanted to display my password characters as a bullet versus the default asterisk (“*”).
I thought this would be pretty simple to do but realized after digging through the Flex 4 SDK that there was no public property I could set to change this. I tried hacking commitProperties and a couple of other methods but came up short in those areas as well until I found the exact spot in the Flex libraries where this character was defined:
RichEditableText.as (line 679)
1 2 3 4 | /** * @private */ mx_internal var passwordChar:String = "*"; |
A-ha! I see here that it’s prefixed with the “mx_internal” namespace and I remembered from other examples around the web that you can easily tap into that namespace and modify properties not normally meant to be modified.
Luckily, I had already extended the TextInput class for various other reasons and decided to add an event listener for the CREATION_COMPLETE lifecycle event of the component. This was added in the constructor:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | import mx.core.mx_internal; /** * Constructor */ public function myTextInput() { super(); this.addEventListener( FlexEvent.CREATION_COMPLETE, onCreationComplete ); } private function onCreationComplete( event : FlexEvent ) : void { //change internal passwordChar to a bullet versus an asterisk this.textDisplay.mx_internal::passwordChar = "●"; } |
…and voila! By tapping into the mx_internal namespace, I found I could modify the normally private variable “passwordChar” and set it to something I preferred better (in this case, the bullet point used in some sites like Twitter).
Hope this helps someone!
Quality content is the key to invite the viewers to pay a quick visit the website, that’s what this
web page is providing.
Only The Perfect Unique Bridal Shower Games 하이오피사이트
Dance Party 부달주소
Make Connections For Your Network: Ideal Holiday Gift Of Networking 출장
Great blog here! Also your site loads up fast!
What web host are you using? Can I get your affiliate link to your host?
I wish my website loaded up as quickly as yours lol
12345678910
Top Kids’ Birthday Party Questions Answered OP
How For Being A Banking Customer Vip 하이오피사이트
Dating Advice For Guys – 3 Common Mistakes Guys Make In Clubs 인천유흥
What’s up Dear, are you really visiting this website daily, if so afterward
you will definitely take pleasant know-how.
Fast Bank Loans Can Be Used For Just About Anything 다바오 취사 가능한 호텔
How To Structure Some Text Follow Up Series 문의 에볼루션 (www.smuniverse.com)
Every weekend i used to visit this website, because i want
enjoyment, since this this site conations genuinely good funny material
too.
I’ve been exploring for a bit for any high quality articles or weblog posts on this kind of space .
Exploring in Yahoo I finally stumbled upon this website. Reading this
information So i’m happy to convey that I have an incredibly good uncanny feeling I came upon just what I
needed. I such a lot surely will make certain to don?t overlook this web site and provides it a glance regularly.
Using Your Hot Tub For Ultimate Relaxation 부달주소
id=”firstHeading” class=”firstHeading mw-first-heading”>Search results
Help
English
Tools
Tools
move to sidebar hide
Actions
General
I wanted to thank you for this fantastic read!!
I definitely loved every bit of it. I have you bookmarked to
look at new things you post…
Nightlife The Actual Deer Valley Area 하이오피
How To Accurately Trace Any Phone Number Online GOLDPAY
You really make it seem so easy with your presentation but I find
this matter to be really something which I think I would never understand.
It seems too complex and extremely broad for me. I’m looking
forward for your next post, I will try to get the
hang of it!
Ahaa, its pleasant discfussion on tthe topic of this
piece of writing at this plaqce at this blog, I have read all that, so noww me also commenting here.
고혼진 화장품 가격
Social Club 부산부달
It’s an awesome article designed for all the web people; they will obtain advantage from it
I am sure.
Wine Tasting 잠실오피
Private Club 하이오피주소
10 Buying A Great Massage 테라피 (Blondell)
After Hours 알밤
id=”firstHeading” class=”firstHeading mw-first-heading”>Search results
Help
English
Tools
Tools
move to sidebar hide
Actions
General
VIP Lounge budal
Hello Dear, are you really visiting this web page on a regular basis,
if so then you will definitely take nice know-how.
관절보궁효능
Consider These Beach Destinations For A Vacation 부달최신주소 (L.V.Eli.Ne.S.Swxzu@Hu.Feng.Ku.Angn..Ub…Xn–.U.K37@Www.Mandolinman.It)
Cocktail Lounge OP (Gertrude)
Nightlife 부산달리기; fianresearch.com,
Very good information. Lucky me I came across your website by chance (stumbleupon).
I have book marked it for later!
Building Your Individual Brand Will Build Your Bank Account
다바오 하는법
Great blog here! Also your site loads up very fast!
What web host are you using? Can I get your affiliate link
to your host? I wish my site loaded up as quickly as yours lol
Take Your Date For Ottawa Karaoke Bar 하이오피주소
Gentlemen’s Club 부산유흥
Nightlife In Patong And The Rest Of Phuket 하이오피사이트
Club Dresses That Can Make Your Evening 유흥
Poker Tools – Gain The Edge 에볼루션 검증
The ideological considerations of the highest order, as well as the semantic analysis of external counteraction, largely determines the importance of the relevant conditions of activation. The clarity of our position is obvious: the boundary of personnel training requires determining and clarifying innovative process management methods.
Cocktail Bar 울산
https://veikkaajille.com/
You have made your position quite well!!
Every phone on this listing has been completely examined by CNET’s professional assesses team.
4 Methods To Integrate Pop Music Into The Entire Life hiop
Baccarat Strategy — A Simple Way November 23 소녀 에볼루션 티어표
Bachelorette Party Planning – Ideas For That Budget
Conscious 밤문화
My brother recommended I might like this website. He was entirely right.
This post actually made my day. You cann’t imagine just how much time I had spent for this
information! Thanks!
Vip Cards – Gives Instant Recognition 오피 (http://catx00X.hypermart.net/cgi-bin/mkaki0864c/mkakikomitai.cgi)