SitePoint Sponsor

User Tag List

Results 1 to 13 of 13
  1. #1
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Operating-System Style Context Menu

    I worked for a while on this, just got it to a pretty much workable state.

    You guys can check it out if you want, http://develop.halfwitt.net/cursor.php

    [img]images/smilies/smile.gif[/img]

    (Right click on the 'Cyborg' link)

    (Note: it won't work in Opera, no oncontextmenu event in Opera)
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.

  2. #2
    SitePoint Guru Vincent Puglia's Avatar
    Join Date
    Feb 2000
    Location
    where the World once stood
    Posts
    700
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    And the question?
    Vinny
    Where the World Once Stood
    the blades of grass
    cut me still

  3. #3
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    No question, just posting it in case someone wanted to use something similar.
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.

  4. #4
    The knight who said ni! RockyShark's Avatar
    Join Date
    Apr 2003
    Location
    Rockhampton, Australia
    Posts
    699
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Cool! I don't have a use for it right now... But I've saved your file to my resources folder for later use!

    Cheers!

  5. #5
    SitePoint Wizard silver trophy redemption's Avatar
    Join Date
    Sep 2001
    Location
    Singapore
    Posts
    5,269
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for that Jeff! It's pretty cool.

    I've seen this in Convea (you need to sign up for an account to access the demo) and wondered how it was done.

  6. #6
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by redemption
    Thanks for that Jeff! It's pretty cool.

    I've seen this in Convea (you need to sign up for an account to access the demo) and wondered how it was done.
    Wow, talk about a lot of Scripting going into that...

    I'm not a fan of the loading times all the time; and I am on 1500/512 DSL!
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.

  7. #7
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Okay, now I am having a problem, I am using the appendChild() method to apply a table for if you have an icon for one of the options, and it is not showing up at all in IE...

    It works perfectly in Mozilla, and I can see it is indeed in the source by using alert(document.body.innerHTML), but it's just not showing up...

    Any ideas?
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.

  8. #8
    SitePoint Member
    Join Date
    Aug 2003
    Location
    new york
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Jeff Lange
    I am using the appendChild() method to apply a table for if you have an icon for one of the options, and it is not showing up at all in IE...
    If you are building the table dynamically, it seems like you may be forgetting to add the TBODY element. It is required in IE when building tables through the DOM.

  9. #9
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    thanks! I remember that now!


    On to one of my final problems... anyone know why setAttribute('cellspacing', '0') and setAttribute('cellpadding', '0'), are resulting in no changes to the table at all in IE?

    I fixed the padding by applying CSS padding to 0 for each cell, but what about cellspacing?


    Thanks for all the help!
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.

  10. #10
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Problem solved! It seems IE needs to have cellspacing and cellpadding set with camel casing:

    Code:
    table.setAttribute('cellSpacing', '0');
    table.setAttribute('cellPadding', '0');
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.

  11. #11
    SitePoint Evangelist ucahg's Avatar
    Join Date
    Apr 2001
    Location
    Sarnia, Ontario, Canada
    Posts
    434
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Impressive, I like it a lot.

    It's too bad it doesn't work in Opera, and while there probably is methods to make it work, I believe that in a good design, the context menu would be optional in the first place, and nothing is in it that cannot be accessed by other means.
    Love it? Hate it? Helpful? Useless?
    Use the rate button to let me know what you think of my post!

  12. #12
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This may sound like pure madness, but does anyone have a copy of this file I posted up, haha... Total shot in the dark!

    I found an old copy of it, and it actually works in Opera now which is cool, however the version I have has no icon capability, and I'd love to have that back without having to spend a retarded amount of time coding it again, haha.

    EDIT: Also, I'd like to point out, after looking at my source code for this, I used to have some Javascript skills... If I tried to write this script now, I'd be lost... haha. Wow, I can't believe how much I'd forgotten.

    Jeff
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.

  13. #13
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    In case anyone cares to take a peek at the version I do have:

    http://jeff.supramania.com/cursor.php

    Thanks again!

    Jeff
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •