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)

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!

Categories: Adobe Flex Tags:
  1. January 19th, 2025 at 07:27 | #1

    Howdy would you mind letting me know which webhost
    you’re working with? I’ve loaded your blog in 3 different internet browsers and I must say this blog loads
    a lot quicker then most. Can you suggest a good internet hosting provider at a reasonable price?
    Thanks a lot, I appreciate it!

  2. January 19th, 2025 at 07:37 | #2

    Advantages Of Mystery Shopping As An Internet Business 광주휴게텔 (Http://Www.Chihuahua.Abc64.Ru/Out.Php?Link=Http://Kwaliteitopmaat.Org/Index.Php?Url=Http://Aha.Ru/~Fordmax/Wwwboard/Messages/324.Html)

  3. January 19th, 2025 at 07:58 | #3

    I am actually glad to glance at this blog posts which contains tons of valuable information, thanks for providing these kinds of statistics.

  4. January 19th, 2025 at 07:59 | #4

    How To Have A Car With A Bad – Detail By Detail goldpay

  5. January 19th, 2025 at 08:03 | #5

    Draft Beer – What Sort Of Bars Serve Draft Draft Beer?
    유흥사이트 (Jeana)

  6. January 19th, 2025 at 08:13 | #6

    Clubbing 부달최신주소

  7. January 19th, 2025 at 08:31 | #7

    Adverse Credit Personal Loan Offers Varied Choices! 다바오 머니 분양

  8. January 19th, 2025 at 08:31 | #8

    Natural The Loss Of Hair Treatment For Female That Work 하이오피주소

  9. January 19th, 2025 at 08:38 | #9

    How To Prepare For Bank Interview – Some Handy Tips 다바오 kyc [servergit.itb.edu.ec]

  10. January 19th, 2025 at 08:38 | #10

    Bank Owned Real Estate – Profiting From The Reo Game
    4989 다바오

  11. January 19th, 2025 at 08:47 | #11

    This is really interesting, You are a very skilled blogger.
    I have joined your rss feed and look forward to seeking more of your excellent post.
    Also, I’ve shared your site in my social networks!

  12. January 19th, 2025 at 08:57 | #12

    Wow, amazing weblog layout! How long have you been blogging for?
    you make running a blog glance easy. The overall glance of
    your site is wonderful, let alone the content
    material!

  13. January 19th, 2025 at 09:08 | #13

    Know Easy Methods To Shop For That Designer Dress Online 골드페이

  14. January 19th, 2025 at 09:13 | #14

    3 Attributes Of Using A Content Management System 하이오피

  15. January 19th, 2025 at 09:15 | #15

    I know this if off topic but I’m looking into starting my
    own weblog and was curious what all is required to get set up?

    I’m assuming having a blog like yours would cost a pretty
    penny? I’m not very web savvy so I’m not 100% sure. Any suggestions or advice would be greatly appreciated.
    Appreciate it

  16. January 19th, 2025 at 09:25 | #16

    After Hours 선릉오피 [Rosetta]

  17. January 19th, 2025 at 09:41 | #17

    The high level of involvement of representatives of the target audience is a clear evidence of a simple fact: the semantic analysis of external oppositions unambiguously defines each participant as capable of making his own decisions regarding the analysis of existing patterns of behavior. For the modern world, the new model of organizational activity leaves no chance for the distribution of internal reserves and resources.

  18. January 19th, 2025 at 09:47 | #18

    What Kinds Of Massage Therapy Are Also There? 하이오피

  19. January 19th, 2025 at 09:52 | #19

    Night Life In Orlando – Universal And Disney Compete For Your Entertainment Audience 부산부달

  20. January 19th, 2025 at 09:53 | #20

    We’re a group of volunteers and starting a new scheme in our community.

    Your web site offered us with valuable information to work on. You’ve done an impressive job and our entire
    community will be thankful to you.

  21. January 19th, 2025 at 10:02 | #21

    Wedding Reception Music – Top 10 Tips 알밤

  22. January 19th, 2025 at 10:12 | #22

    Aw, this was a very nice post. Spending some time and actual effort to create a very good article…
    but what can I say… I put things off a lot and never manage
    to get anything done.

  23. January 19th, 2025 at 10:13 | #23

    Create A Magic Knowledge Of Clients, Leads, And Colleagues Part I 다바오머니상 (Wargame.Ch)

  24. January 19th, 2025 at 10:16 | #24

    Shopping, Fashion And Nightlife In Antwerp, Belgium op

  25. January 19th, 2025 at 10:18 | #25

    Have you ever thought about creating an ebook or guest authoring on other
    sites? I have a blog centered on the same topics you discuss
    and would love to have you share some stories/information. I know
    my audience would enjoy your work. If you’re even remotely interested, feel free to shoot
    me an e-mail.

  26. January 19th, 2025 at 10:21 | #26

    If you are going for best contents like me, simply go to
    see this web site everyday for the reason that it provides quality contents,
    thanks

  27. January 19th, 2025 at 10:52 | #27

    I wanted to thank you for this fantastic read!! I absolutely loved
    every little bit of it. I have you book-marked to
    check out new things you post…

  28. January 19th, 2025 at 11:04 | #28

    How Any Good Thai Massage – 5 Simple Ways 하이오피주소

  29. January 19th, 2025 at 11:11 | #29

    A swanky London steakhouse is facing backlash over its introduction of charges for
    tablecloths and napkins.

    Diners at the London Steakhouse restaurant, which was opened by celebrity chef Marco
    Pierre White in 2008, are now expected to fork out an additional cover of £1.50 per person.

    The restaurant, located near Liverpool Street train station,
    has stated that this will be a fixed fee ‘to cover the cost of table linen and napkins’, with a discretionary service charge of 9.5 per
    cent also appearing on bills.

    Industry experts have cautioned though that this could be just the start of restaurants seeking more ‘innovative’ ways to raise additional
    revenue from customers.

    Off the back of the government’s autumn budget which saw both the minimum wage and national insurance rates increase, restauranteurs have been warning that prices must rise for them to be able to foot the bill.

    From April, the national minimum wage will increase by
    6.7 per cent to £12.21 per hour, with employer’s
    NI charges to jump by 1.2 per cent. 

    Conservative party leader Kemi Badenoch has previously claimed
    the national minimum wage is detrimental to British businesses, and told this year’s Tory conference that it
    was ‘over-burdening’ many small enterprises.

    The London Steakhouse appears to be reacting proactively to
    its impending expenditure increases, through both the
    tablecloth and napkin fee along with a host of other charges.

    Marco Pierre White’s (pictured) London Steakhouse
    has come under fire over the introduction of charges for
    tablecloths and napkins

    The London Steakhouse restaurant (pictured) has been open near Liverpool Street station since
    2008

    Diners are now expected to fork out an additional £1.50 per head for tablecloths and napkins

    Be the first to commentBe one of the first to commentComments

    Would you pay for the napkin fee?

    Comment now
    The charges for the linen are displayed on the restaurant’s à la carte
    menu, with the set menus seeing additional charges such as
    a £1 head cover fee.

    A 12.5 per cent service charge is also added to set
    menu bills, as the self-proclaimed ‘linen-topped table dining’ establishment seemingly seeks more
    ways to charge patrons.

    The cover charge concept is one which is standard practice in many places around Europe, particularly
    in Italy where the ‘coperto’ charge covers table linen and bread.

    Cover charges are becoming ever more prevalent in the UK,
    with Harrdos also recently jumping on the trend and implementing a £1 levy at
    its London eateries.

    Other charges laid out on the London Steakhouse’s website
    include a £10 fee for booking certain set menus
    over two days in advance.

    This fee is not considered as a deposit by the restaurant and
    is not credited from your final bill, but rather a charge simply allowing
    you to make your reservation. 

    Consumer specialist Jane Hawkes told the Telegraph that the introduction of such fees is unfair on diners and that customers should be made to feel valued
    by businesses, rather than ‘bamboozled’.

    One potential unintended consequence of these fee
    introductions is that patrons will feel less obliged to
    pay service charges or leave behind tips.

    Despite new legislation coming into effect in October which ensures staff receive equal distribution of tips, industry expert Ms Hawkes says that
    this may prove to be redundant if fee gouging persists. 

    The London Steakhouse restaurant has been approached by the MailOnline for comment. 

    ItalyMarco Pierre WhiteKemi Badenoch

  30. January 19th, 2025 at 11:19 | #30

    The only 3-digit number that has factors of 2
    and 7 is 14. Factors are numbers that can be multiplied to give the
    number in question. In this case, 2 x 7 = 14,
    Read more

    Math and Arithmetic

    +2

    What is the value of the digit 4 in number 14?

    Asked by Wiki User

    Well, hello there! The digit 4 in the number 14 holds a special place,
    like a little tree in a big forest. It has a value of 4, which means it represents four u
    Read more

    Statistics

    What is a fair number?

    Asked by Wiki User

    I’m assuming that when you say ‘fair number’, you’re talking
    about the saying “A fair number of people think…”, correct?
    In that sense, there really is no har
    Read more

    Statistics

    What do you mean by backlash error of spherometer?

    Asked by Wiki User

    The backlash error of a spherometer refers to the discrepancy in measurements due to the presence of mechanical play or slack in the instrument’s components.
    Th
    Read more

    Statistics

    Is the yes or no survey question discrete or continuous?

    Asked by Wiki User

    A yes or no survey question is considered a discrete variable.
    Discrete variables have distinct, separate values with no possible values in between. In this cas
    Read more

    Math and Arithmetic

    +2

    How many combinations of 2 numbers are there in 5 numbers?

    Asked by Wiki User

    Oh, dude, you’re hitting me with some math vibes.
    So, to figure out how many combinations of 2 numbers you can make from a set of 5 numbers, you use the formula
    Read more

    Math and Arithmetic

    +1

    What are the most frequent 3 digit combination?

    Asked by Wiki User

    Well, isn’t that a happy little question! The most frequent 3-digit combination is
    likely 123, as it follows a simple pattern and is easy to remember.
    But remem
    Read more

    Math and Arithmetic

    +2

    What does ‘Cu’ mean in mathematics?

    Asked by Wiki User

    In mathematics, ‘Cu’ typically stands for the symbol of the element copper on the periodic table.
    Copper is a transition metal with the atomic number 29 and the
    Read more

    Religion & Spirituality

    +4

    How many Suras in the Qur’an start with alhamdulillah?

    Asked by Wiki User

    Well honey, there are 38 Suras in the Qur’an that start with “Alhamdulillah.” So, if you’re looking to spread some gratitude,
    you’ve got plenty of ver
    Read more

    Statistics

    What is the geometric mean of 9 and 35?

    Asked by Wiki User

    The geometric mean of two numbers is the square root of their product.
    In this case, the geometric mean of 9 and 35 would be the square root of (9 * 35), which
    Read more

    Math and Arithmetic

    +2

    What type of data cannot be shown in a stem and leaf plot?

    Asked by Wiki User

    We lazy people don’t know this type of stuff

  31. January 19th, 2025 at 11:20 | #31

    Hi there, its nice paragraph regarding media print, we all be familiar with media is
    a great source of facts.

  32. January 19th, 2025 at 11:26 | #32

    Bank Owned Real Estate – Normally Asked Questions 다바오 커플 호텔

  33. January 19th, 2025 at 11:29 | #33

    Adult Entertainment 광주키스방

  34. January 19th, 2025 at 11:50 | #34

    The Root Causes Of Credit Card Debt 다바오 커플
    호텔

  35. January 19th, 2025 at 11:53 | #35

    This is my first time pay a visit at here and i am actually impressed to read everthing at one place.

  36. January 19th, 2025 at 11:57 | #36

    If you desire to take much from this piece of writing then you have
    to apply these methods to your won webpage.

  37. January 19th, 2025 at 11:57 | #37

    4 Marketing Myths Threaten Your Sales 다바오4989 (Will)

  38. January 19th, 2025 at 12:04 | #38

    Top Summer Tips For Retirees op

  39. January 19th, 2025 at 12:32 | #39

    Instant Decision Tenant Loan – No Credit Go To! 다바오 투어

  40. January 19th, 2025 at 12:56 | #40

    I every time used to read post in news papers but now as I am a user of net so from now I am using net
    for articles or reviews, thanks to web.

  41. January 19th, 2025 at 13:11 | #41

    Awesome! Its in fact awesome article, I have got much clear
    idea concerning from this post.

  42. January 19th, 2025 at 13:12 | #42

    Hotels In New York City The Majority Of Affordable
    Rate 하이오피

  43. January 19th, 2025 at 13:15 | #43

    Купите свою идеальную квартиру!

    Ищете комфорт и уют? У нас есть решение!

    Современная квартира в центре города:
    - Просторные комнаты и современный дизайн.

    - В шаговой доступности магазины,
    школы и парки.
    - Хорошая инвестиция: растущие цены на жилье!

    Не упустите шанс! Запишитесь на просмотр
    и станьте владельцем квартиры своей мечты!

    Звоните сейчас!==>>>
    элевен москва жк купить

  44. January 19th, 2025 at 13:19 | #44

    Pretty nice post. I just stumbled upon your blog and wished to mention that
    I’ve really enjoyed surfing around your blog posts.
    In any case I will be subscribing in your feed and I’m hoping you write once more
    soon!

  45. January 19th, 2025 at 13:32 | #45

    Fat Management Programs – How Assess The Good, Bad And Incredibly Ugly Ones
    유흥사이트 (http://gspara01.Dothome.co.kr)

  46. January 19th, 2025 at 13:33 | #46

    The Best Time To Buy Beach Condos Is Now 부달주소

  47. January 19th, 2025 at 13:41 | #47

    Top 6 Business Success Strategies OP

  48. January 19th, 2025 at 13:46 | #48

    Paragraph writing is also a fun, if you be acquainted with afterward you can write or else it is difficult to write.

  49. January 19th, 2025 at 13:59 | #49

    Excellent post. I’m experiencing many of these issues as well..

  50. January 19th, 2025 at 14:43 | #50

    5 Best Financial Apps For The Iphone, Itouch And Ipad 다바오머니

Comment pages
1 111 112 113 114 115 147 435
  1. March 19th, 2014 at 11:13 | #1
  2. April 30th, 2014 at 01:00 | #2
  3. December 31st, 2018 at 08:24 | #3
  4. February 2nd, 2019 at 20:25 | #4
  5. January 25th, 2020 at 13:25 | #5
  6. March 28th, 2020 at 20:22 | #6
  7. March 30th, 2020 at 22:25 | #7
  8. July 2nd, 2020 at 04:14 | #8
  9. November 26th, 2023 at 17:35 | #9
  10. June 17th, 2024 at 01:33 | #10
  11. July 9th, 2024 at 09:52 | #11
  12. July 29th, 2024 at 03:40 | #12
  13. September 16th, 2024 at 11:50 | #13
  14. October 19th, 2024 at 15:31 | #14
  15. October 22nd, 2024 at 18:24 | #15
  16. October 24th, 2024 at 04:17 | #16
  17. November 9th, 2024 at 10:01 | #17
  18. November 9th, 2024 at 11:51 | #18
  19. November 11th, 2024 at 04:18 | #19
  20. November 11th, 2024 at 06:33 | #20
  21. November 11th, 2024 at 07:08 | #21
  22. November 12th, 2024 at 02:12 | #22
  23. November 13th, 2024 at 08:00 | #23
  24. November 14th, 2024 at 06:12 | #24
  25. November 14th, 2024 at 14:35 | #25
  26. November 14th, 2024 at 16:23 | #26
  27. November 15th, 2024 at 05:09 | #27
  28. November 15th, 2024 at 05:46 | #28
  29. November 15th, 2024 at 11:13 | #29
  30. November 15th, 2024 at 11:46 | #30
  31. November 15th, 2024 at 19:12 | #31
  32. November 17th, 2024 at 04:29 | #32
  33. November 18th, 2024 at 05:00 | #33
  34. November 19th, 2024 at 12:11 | #34
  35. November 19th, 2024 at 19:46 | #35
  36. November 25th, 2024 at 21:09 | #36
  37. December 4th, 2024 at 00:57 | #37
  38. December 30th, 2024 at 18:41 | #38
  39. January 6th, 2025 at 21:21 | #39
  40. January 21st, 2025 at 19:12 | #40
  41. January 21st, 2025 at 19:27 | #41
  42. January 21st, 2025 at 21:18 | #42
  43. January 21st, 2025 at 21:20 | #43
  44. January 21st, 2025 at 21:34 | #44
  45. January 21st, 2025 at 22:46 | #45
  46. January 21st, 2025 at 23:10 | #46
  47. January 21st, 2025 at 23:38 | #47
  48. January 22nd, 2025 at 01:51 | #48
  49. January 22nd, 2025 at 03:06 | #49
  50. January 22nd, 2025 at 03:11 | #50
  51. January 22nd, 2025 at 05:36 | #51
  52. January 22nd, 2025 at 07:18 | #52
  53. January 22nd, 2025 at 08:20 | #53
  54. January 22nd, 2025 at 08:48 | #54
  55. January 22nd, 2025 at 08:49 | #55
  56. January 22nd, 2025 at 08:54 | #56
  57. January 22nd, 2025 at 09:01 | #57
  58. January 22nd, 2025 at 09:06 | #58
  59. January 22nd, 2025 at 09:45 | #59
  60. January 22nd, 2025 at 09:59 | #60
  61. January 22nd, 2025 at 10:50 | #61
  62. January 22nd, 2025 at 11:00 | #62
  63. January 22nd, 2025 at 11:35 | #63
  64. January 22nd, 2025 at 14:26 | #64
  65. January 22nd, 2025 at 15:11 | #65
  66. January 22nd, 2025 at 15:29 | #66