Closed (works as designed)
Project:
Fusion
Version:
6.x-1.0-rc1
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
16 Jun 2010 at 23:00 UTC
Updated:
6 Aug 2011 at 17:51 UTC
I have a Fusion sub theme with a superfish menu. When the menu items go down to the bottom of the available screen the menu pushes up. Is there any way to prevent this? It does not happen to menu's on the Superfish example site.
http://dl.dropbox.com/u/30035/bad.png
http://dl.dropbox.com/u/30035/good.png
http://dl.dropbox.com/u/30035/superfish_example.png
Comments
Comment #1
agerson commentedIts actually a feature, not a bug:
http://users.tpg.com.au/j_birch/plugins/superfish/supposition-test/
To remove it go to script.js in your sub-theme and change:
to
Comment #2
agerson commentedComment #3
jeremycaldwell commentedThat is correct agerson, thanks. It is a feature of the Superfish menu but can be disabled by making a change to your theme.
This code appears in Fusion Core's script.js file (/js/script.js) and controls the display of the Superfish menu.
Notice the ".supposition();" on both of those behaviors, that is what is doing the placement of your menus. Now to adjust this and change it you need to copy the above code to your subtheme's script.js file located in your /js folder. If there isn't one there create one. Now paste the code there and change the two instanced of "Drupal.behaviors.fusion" to "Drupal.behaviors.THEMENAME" where THEMENAME is the name of your theme, info file, and subtheme folder (they are the same).
Then make sure to add the new script file to be called by your theme in the subtheme's .info file.
Then go back to your site and clear the cache and it should reload your site and theme with the updated script.js file and your menu changes.
Comment #4
SuleymanK commentedI added this code ion my script.js file to open menus immediately. My script.js is in the .info file.
I get this error in firebug:
$("#primary_links ul.sf-menu").superfish({hoverClass: "sfHover", delay: 0, animation: {opacity: "none", height: "none"}, speed: "fast", autoArrows: false, dropShadows: false, disableHI: true}).supposition is not a function.
now anyone this issue?
Comment #6
priyanka.salunke commentedm not getting actually wht to do
plz specify the filename whtever we hv to change
becoz in script .js m nt getting this code
Comment #7
priyanka.salunke commentedjst see this file
Comment #8
manos_ws commentedI think the best solution would be not to disable the supposition effect but to fix it.
The problem is in the supposition.js at the line 52
which does not considers the current position of the u.
If you change this with this
Please review the code. This should be fixed in the fusion core supposition.js in a future update.
I am not familiar with the patching system so I can't write a patch for it.
ManosK
http://websynergy.gr/
Comment #9
pixelpreview@gmail.com commentedI have the same problem
Create a file supposition.js on your js folder in your sub-theme
paste the code from the original file in fusion core
comment theses lines
if (expandUp) {
$u.css('margin-top',baseline - (menuHeight + offsetTop));
}
change your site.info and add these line
scripts[]= js/supposition.js
now fusion superfish will use your js file :-)
Comment #10
aquariumtap commentedComment #11
manos_ws commentedThis issue is not fixed!
A change should be made in fusion supposition.js