From e02efd2ed0586cee9d6be28557ca74afaa3d550b Mon Sep 17 00:00:00 2001 From: falkTX Date: Mon, 7 Apr 2014 17:45:28 +0100 Subject: [PATCH] Update to top menus --- css/style.css | 8 ++-- images/ico_chat.png | Bin 0 -> 1373 bytes images/ico_forum.png | Bin 0 -> 474 bytes images/ico_soundcloud.png | Bin 0 -> 549 bytes includes/header.php | 77 ++++++++++++++++++++++++++++---------- 5 files changed, 62 insertions(+), 23 deletions(-) create mode 100644 images/ico_chat.png create mode 100644 images/ico_forum.png create mode 100644 images/ico_soundcloud.png diff --git a/css/style.css b/css/style.css index f1491f2..5b54aba 100644 --- a/css/style.css +++ b/css/style.css @@ -432,7 +432,7 @@ fieldset table { background:none repeat scroll 0 0 transparent; } -#div_menuSoftware { +.div_menuDropdown { position: absolute; top: 30px; left: 0px; @@ -444,7 +444,7 @@ fieldset table { z-index: 99; } -#div_menuSoftware p { +.div_menuDropdown p { color: #F0F0F0; margin: 0 0 0 0; padding-top: 4px; @@ -455,12 +455,12 @@ fieldset table { border-top: 0px; } -#div_menuSoftware a { +.div_menuDropdown a { color: #F0F0F0; text-decoration: none; } -#div_menuSoftware a:hover, #div_menuSoftware a:focus { +.div_menuDropdown a:hover, .div_menuDropdown a:focus { color: #6464E6; } diff --git a/images/ico_chat.png b/images/ico_chat.png new file mode 100644 index 0000000000000000000000000000000000000000..d9e13d3b31268e26083bcce3d090d6539ef9afc1 GIT binary patch literal 1373 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!63?wyl`GbKJOS+@4BLl<6e(pbstPBjy3;{kN zu0U}WUS2cX7<2D@59eSf?^OSwwD733{L0FLs;bzcrm&jTVRdW5>oz5nwaYL%;P3RX7hTau1GmtT);T1?fG)Y?p3~T z?i_q6ml3vd&cU#Ag^@Z_jZ(Fi)c)VhE`GD5@zcp4|JE^ESo=R)DeE_9*ET`#mfI%$ zOZ#HwT!I%`7V1|>6jp2$e{*uXjV)Ks9G{ujH2BmsWS3j3^P6Cas+bEXGnzjS~7S>C1063#gRZoZXpo?UDWK zH;3!(AMHp=>wCx}ru4`?&CIYT{)L;1exD$JBHwd^*7XucRM$Mv5qm6u$W3?tBd)y1 zBG*1F;(4cZF>}g_nKR#>$ywYeUC~qiqwoHWL!mv1va)Af(%f902zK$>9QR9%KVtK4 zL2vjAmm_7|XV27hsJ{@q#s21@@w((K7upSbpLX166O&62+RpVrdfvkJ>WYxYgWi7* zy3OC#Sjcmwj-T7KykPS@!F$(#-tMq?A-zRw!s*uief~2JimwSP*!`p9dg_<$6OBIG zyh~=8UD2#6^FT_iU}4eB-i~*H%`3Edro2d(-)Qx|M0J1s)_W&^`Ls7HG(|=_zfMgS{pFa0yysh=*JPD07)a@I)Ist+&zHuI0OVCBuGO6 zt;*~S48vJz_X0Qy6`;(T1Ztikg@VR|r&#MO>EI3hS5Hv>16M_Jg9-vkA_-EXja$2e z-?&FSc#B)QhBe!`#jDWnP(0hhyRsSyoCGNgq%2_To1A>OjV-UEB#3EbivIE~{LTBM zxr?MMAix2TN8H91)>(rjR0E^N_5h8|$25A|D34VI07bxExm^O120Dm;RspyRs}RcE z&H(a&KEKCe!lY8yEliO3`XzRlVFnf-A$>hvO@0TWg0#z|x - function itemSoftwareClicked(event){ + function closeAllMenus(){ + var objSoftwareMenu = document.getElementById("div_menuSoftware"); + var objRepositoriesMenu = document.getElementById("div_menuRepositories"); + var objSupportMenu = document.getElementById("div_menuSupport"); + var objCommunityMenu = document.getElementById("div_menuCommunity"); + + if (objSoftwareMenu.style.visibility == "visible") + objSoftwareMenu.style.visibility = "hidden"; + + if (objRepositoriesMenu.style.visibility == "visible") + objRepositoriesMenu.style.visibility = "hidden"; + + if (objSupportMenu.style.visibility == "visible") + objSupportMenu.style.visibility = "hidden"; + + if (objCommunityMenu.style.visibility == "visible") + objCommunityMenu.style.visibility = "hidden"; + }; + + function menuItemClicked(event, menu, itemName){ event.stopPropagation(); - var objSoftwareMenu = document.getElementById("div_menuSoftware"); + closeAllMenus(); - if (objSoftwareMenu.style.visibility != "visible") - { - var leftPos = document.getElementById("item-soft").getBoundingClientRect().left - 1; - objSoftwareMenu.style.left = "" + leftPos + "px"; - objSoftwareMenu.style.visibility = "visible"; - } - else + //if (menu.style.visibility != "visible") { - objSoftwareMenu.style.visibility = "hidden"; + var leftPos = document.getElementById(itemName).getBoundingClientRect().left - 1; + menu.style.left = "" + leftPos + "px"; + menu.style.visibility = "visible"; } + //else + //{ + // menu.style.visibility = "hidden"; + //} return false; }; function bodyClicked(){ - var objSoftwareMenu = document.getElementById("div_menuSoftware"); - - if (objSoftwareMenu.style.visibility == "visible") - objSoftwareMenu.style.visibility = "hidden"; - + closeAllMenus(); return true; }; + + function itemSoftwareClicked(event) { return menuItemClicked(event, document.getElementById("div_menuSoftware"), "item-soft"); }; + function itemRepositoriesClicked(event){ return menuItemClicked(event, document.getElementById("div_menuRepositories"), "item-repos"); }; + function itemSupportClicked(event) { return menuItemClicked(event, document.getElementById("div_menuSupport"), "item-support"); }; + function itemCommunityClicked(event) { return menuItemClicked(event, document.getElementById("div_menuCommunity"), "item-community"); }; +