Home > Adobe Flex > Flex 4: Changing the “displayAsPassword” default character

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)

     *  @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:

import mx.core.mx_internal;
 * Constructor
public function myTextInput()
	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!

Categories: Adobe Flex Tags:
  1. September 11th, 2016 at 19:37 | #1

    Ꮋelⅼo! I’ve Ƅeen reading your blog fοr a long time now and finally got the bravery tօ go ahead and gіve yoou a shout оut frim New Caney Tx!
    Just wanteⅾ tߋ tᥱll you keeρ ᥙρ tҺe grᥱat job!

  2. September 14th, 2016 at 18:13 | #2

    Richard Jaeckel appears as a former colleague of Lancaster’s and Roscoe
    Lee Browne as a college professor early-on pleading for
    the release of an imprisoned militant. It makes sense that
    we recognize it again on its fiftieth anniversary
    as it shows how unique Hitchcock’s powers of manipulation were and how hard
    they are to duplicate. Hicks, murderers, druggies and poorly prepped hospitals.

  3. September 16th, 2016 at 03:17 | #3

    I don’t even know the way I finished up right here, however I assumed this submit used to be great.

    I do not realize who you are however definitely you are going
    to a famous blogger for those who aren’t already. Cheers!

  4. September 17th, 2016 at 20:27 | #4

    But whoever wibs the Republican nomination must compete
    for Latino voters in 2016 — and if the Republican nominee endorses Trump’s proposals iin 2015, the Democratic nomineee is unlikely to let voters neglect about that in 2016.

  5. September 27th, 2016 at 03:44 | #5

    Superb, what a web site it is! This webpage gives useful information to us,
    keep it up.

  6. October 5th, 2016 at 16:57 | #6

    Wow that was odd. I just wrote an incredibly long comment but after Iclicked submit
    my comment didn’t appear. Grrrr… well I’m not writing all that over again. Regardless, just wanted to
    say fantastic blog!

  7. October 16th, 2016 at 00:55 | #7

    Read and follow the directions carefully.

  8. November 5th, 2016 at 11:34 | #8

    This design is wicked! Youu most certainly know hoow too
    keep a reader amused. Between your wit and your videos,
    I was alnost moved to start myy own blog (well, almost…HaHa!) Wonderful job.
    I rerally loved what you had too say, and more than that,
    how you presented it. Too cool!

  9. November 13th, 2016 at 20:01 | #9

    Your style is uniuque compared to other people I have reqd stuff from.
    I apprecite you for posting when you have the opportunity,
    Guess I will just book mark this blog.

  10. November 14th, 2016 at 01:57 | #10

    payudara indah
    cerita cinta sejati
    masakan jawa
    resep masakan indonesia
    senam hamil
    tutorial make up
    resep buncis
    arti mimpi bersetubuh
    perawatan rambut rontok
    info makanan

  11. November 14th, 2016 at 20:18 | #11

    tempat pensil dari botol bekas
    info rempeyek kacang
    info tips menurunkan berat badan
    resep martabak telur
    perkembangan janin
    cara mengatasi rambut rontok
    mengenai kutu rambut
    tutorial hijab paris
    cara make up
    cara cantik alami

  12. November 15th, 2016 at 12:20 | #12

    puting susu
    penjelasan efek samping pil kb
    manfaat bawang putih
    tentang tanggal lahir jawahttp://bit.ly/2dHAKPM
    Apa itu bunga sakura
    cerita cinta sejati
    ramalan cinta
    tentang masak apa hari ini
    dokter kecantikan

  13. November 15th, 2016 at 14:37 | #13

    daerah sensitif wanita
    penjelasan resep kari ayam
    menu diet mayo
    daun mangkokan
    patah hatihttp://bit.ly/2dOYIYK
    Tentang resep ayam bumbu kecap
    resep makanan ringan
    tutorial jilbab
    tutorial hijab paris
    resep ayam bumbu kecap

  14. November 15th, 2016 at 16:41 | #14

    mengenai menu masakan sehari hari
    tentang model rambut pendek wanita
    info jodoh
    resep masakan jawa
    tentang arti kedutan
    diet alami
    mengenai tempe goreng
    tentang cara diet
    tentang bumbu nasi goreng

  15. November 23rd, 2016 at 13:48 | #15

    This piece of writing iis truly a good oone it assists new internet users,
    whoo are wishing for blogging.

  16. November 24th, 2016 at 10:42 | #16

    Happy to be among the visitors on this awe inspiring web site :

  17. December 10th, 2016 at 10:24 | #17

    Controle su alarma en cualquier momento sitio desde su Smartphone con la aplicación de Alpe Seguridad…… leer más.

  18. December 11th, 2016 at 02:28 | #18

    Hi there to all, the contents existing at this web site
    are genuinely awesome for people experience, well, keep up the nice work fellows.

  19. December 13th, 2016 at 03:26 | #19

    At this point you may attempt to get closer physically by touch, before opportunity comes for the kiss.
    Another popular public location to get naughty with
    your hunny is probably the bathroom. If you fear
    spiders lets say you will inadvertently focus on them.

  20. December 17th, 2016 at 12:36 | #20

    Nosso sítio não pretende ensinar ninguém a ganhar dinheiro, porém
    sim ser um guia para apostador possa conhecer
    todas e cada uma das moradias de apostas
    para mercado brasílio que são de crédito e também que têm credibilidade no mercado.

  21. December 26th, 2016 at 13:28 | #21

    Studying abroad is an excellent method to obtain international experience that enhances your
    business education.

  22. January 7th, 2017 at 08:31 | #22

    Unquestionably believe that which you stated. Your favorite justification seemed to be
    on the web the easiest factor to take into account of. I say to you, I definitely get irked while other folks consider issues that they plainly do not recognise about.
    You managed to hit the nail upon the highest and outlined out the whole thing with
    no need side effect , other folks can take a signal.
    Will likely be back to get more. Thank you

  23. January 9th, 2017 at 07:25 | #23

    I am truly happy tto read this website poksts which carries plenty of
    useful facts, thanks for providing these kinds of information.

  24. January 12th, 2017 at 11:38 | #24

    Hi Dear, are you genuinely visiting this web page regularly, if so afterward you will without doubt get good know-how.

  25. January 20th, 2017 at 03:31 | #25

    Pretty section of content. I just stumbled upon your website and
    in accession capital to assert that I get actually enjoyed account your blog posts.
    Any way I’ll be subscribing to your feeds and even I achievement
    you access consistently fast.

  26. January 21st, 2017 at 22:03 | #26

    With havin so much content do you ever run into any issues of
    plagorism or copyright violation? My site has a lot of completely unique content I’ve either authored myself or outsourced but it appears a lot of it is popping it up all over the internet without my permission. Do
    you know any methods to help prevent content from being ripped off?
    I’d genuinely appreciate it.

  27. February 4th, 2017 at 02:31 | #27

    There is certainly a lot to learn about this subject. I like all of
    the points you made.

  28. February 8th, 2017 at 05:41 | #28

    I am really happy to read this webpage posts which carries tons of helpful facts, thanks for providing such statistics.

  29. February 8th, 2017 at 23:40 | #29

    First of all I want to say awesome blog! I had a quick question which I’d like
    to ask if you do not mind. I was curious to know how you center yourself and
    clear your thoughts before writing. I have had trouble clearing my
    mind in getting my thoughts out. I truly do enjoy writing but it just seems
    like the first 10 to 15 minutes are usually lost simply just trying to figure out how to begin. Any recommendations or hints?

  30. February 14th, 2017 at 10:40 | #30

    If you want to obtain a good deal from this piece of
    writing then you have to apply these methods to your won web site.

  31. February 15th, 2017 at 12:26 | #31

    Click the red switch below as well as you could have access to highly tailored quotes
    from a panel of courier insurance specialists within minutes.

  32. February 15th, 2017 at 17:01 | #32

    A specialists’ responsibility insurance policy gives public responsibility
    insurance policy for working as a consultant work far from your facilities.

  33. February 15th, 2017 at 20:18 | #33

    After much removal, both deciders develop a market
    list of 57 business.

  34. February 15th, 2017 at 22:21 | #34

    In the examination check, the auditor had actually published 284 letters by speed blog post as well
    as 287 by various personal messenger services.

  35. February 17th, 2017 at 21:59 | #35

    Hey There. I found your weblog the use of msn. That is a really well written article.

    I’ll be sure to bookmark it and come back to learn extra of your useful info.
    Thanks for the post. I will certainly comeback.

  36. February 18th, 2017 at 03:56 | #36

    Very good blog! Do you have any suggestions for aspiring writers?
    I’m planning to start my own site soon but I’m a little lost on everything.
    Would you advise starting with a free platform like WordPress or go for a paid option? There are so many choices out there that I’m totally overwhelmed
    .. Any suggestions? Thanks a lot!

  37. February 18th, 2017 at 08:10 | #37

    I pay a visit each day a few web sites and sites to read articles or reviews, but this blog offers feature based writing.

  38. February 24th, 2017 at 06:53 | #38

    What’s up to all, since I am in fact eager of reading this blog’s post to be updated regularly.
    It consists of nice material.

  39. February 25th, 2017 at 23:13 | #39

    If some one needs to be updated with most recent technologies then he must be go to see
    this site and be up to date every day.

  40. February 28th, 2017 at 02:51 | #40

    Scott sell them yourself, don’t let people take advantage of your hard them on Craig list, get a younger person in your area
    to help you with it,they know how to use computers, and u could pay them
    for there help, have shipping cost included in price, just a thought good luck.

  41. February 28th, 2017 at 19:36 | #41

    Wow! Finally I got a webpage from where I be capable of really get useful facts concerning my study and knowledge.

  42. February 28th, 2017 at 21:59 | #42

    It’s High Noon” is a voice line uttered by the hero McCree when using his final capability.

  43. February 28th, 2017 at 22:48 | #43

    In the book, it talks extra about the conventional Asian weight loss plan , and eight steps to stop and management

  44. February 28th, 2017 at 23:39 | #44

    It’s a pity you don’t have a donate button! I’d without a doubt donate to this superb blog!
    I guess for now i’ll settle for bookmarking and adding your RSS feed to my Google account.
    I look forward to fresh updates and will share this website with my Facebook group.

    Talk soon!

  45. March 1st, 2017 at 00:03 | #45


    dogpug ,shih tzu, puppies ,,labrador ,chihuahua ,golden retriever ,german shepherd ,bulldog ,boxer
    dog ,labrador dog ,cute dogs ,dog pictures ,teacup dogs ,boxer puppies ,
    dogs trust ,shih tzu puppies ,dog games ,puppies for sale ,
    dog training ,dog house ,dog crate ,dog kennels ,
    ,australian cattle dog ,pug dog ,pet finder ,black dog ,english bulldog ,cockapoo ,yorkshire terrier

  46. March 1st, 2017 at 01:51 | #46

    Our on-line retailer affords you a singular number of
    enjoyable original graphic printed clothes, loopy, rude offensive t shirts and humorous
    humorous textual content statements & traditional cool vintage model
    retro t shirts for men, ladies, and youngsters.

  47. March 1st, 2017 at 18:44 | #47

    Hi, all is going well here annd occourse every one is sharing data, that’s really good,
    keep up writing.

  48. March 2nd, 2017 at 14:01 | #48

    Thanks to my father who informed me regarding this weblog, this webpage is really remarkable.

  49. March 4th, 2017 at 05:12 | #49

    Clash of Kings is offered in around twenty languages worldwide, and is supposed to capitalize on the
    recognition and success of Game of War: Fire Age , being very
    related in many facets.

  50. March 7th, 2017 at 07:20 | #50

    Overwatch is Blizzard’s fourth main franchise, and took place following
    the 2014 cancellation of the bold massively multiplayer
    online position-enjoying recreation Titan A portion of the Titan crew got here up with the idea of Overwatch, primarily
    based on the success of workforce-based mostly first-person shooters like Team
    Fortress 2 and the rising reputation of multiplayer online battle arenas , making a hero-based shooter that emphasized

Comment pages
1 8 9 10 11 12 14 435
  1. March 19th, 2014 at 11:13 | #1
  2. April 30th, 2014 at 01:00 | #2