marcodeltongo / thematic

Automatically exported from code.google.com/p/thematic
0 stars 0 forks source link

Provide a way to disable default widgets on activation. #59

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Set up some custom widget layout.
2. Deactivate Thematic then reactivate.
3.

What is the expected output? What do you see instead?
Expected out put would be same custom widget instead the default widgets
are install again.

What version of the product are you using? On what operating system?
09.5.1

Please provide any additional information below.

I'd like to see a hook to remove this functionality.

Original issue reported on code.google.com by johnnytee on 7 Dec 2009 at 2:03

GoogleCodeExporter commented 9 years ago
As of r544 there is a way to filter the default widgets using the 
thematic_preset_widgets filter *but* the Problem listed 
here cannot be solved by using this filter.

I have reproduced this problem many times with thematic and with child theme's 
of thematic. Quite annoying actually. The 
solution I'm proposing is simple enough but I believe it needs to happen in 
thematic. 

In widget-extensions.php the conditional for update_options('sidebars_widgets') 
needs to be adjusted to check to see if 
any values exists that is to say it needs to check to see if the user has made 
any edits to the widget arrangement.

Example:

    if ( isset( $_GET['activated'])  && get_option( 'sidebars_widgets') == FALSE ) {
        update_option( 'sidebars_widgets', apply_filters('thematic_preset_widgets',$preset_widgets ));
        }

Thanks-
Gene

Original comment by gene%emh...@gtempaccount.com on 15 Dec 2009 at 5:16

GoogleCodeExporter commented 9 years ago
I believe that I am right in that the original poster's desire to filter the 
default widgets was addressed but was 
wrong about the revision it was not 544 

It is resolved in r554 

 I will start a new issue. For the second part of my message above.

-Gene

Original comment by gene%emh...@gtempaccount.com on 14 Jan 2010 at 9:30

GoogleCodeExporter commented 9 years ago
I now accept this a standard behavior
-Gene 

Original comment by gene%emh...@gtempaccount.com on 25 Feb 2010 at 4:11

GoogleCodeExporter commented 9 years ago

Original comment by eugene.m...@gmail.com on 22 Apr 2010 at 4:08

GoogleCodeExporter commented 9 years ago

Original comment by eugene.m...@gmail.com on 8 Aug 2010 at 3:15