@see title.

When selecting a layout it should then only list the regions declared in the layout.inc file and not the entire list of regions.

Comments

attiks’s picture

You're totally right, any chance you can upload a patch? :-)

fubhy’s picture

sure, was about to do that :p

fubhy’s picture

Status: Active » Needs review
StatusFileSize
new8.5 KB

Forgive my impudence... I touched a bit more than I initially wanted. Anyways, tried to build this around the existing reaction plugin for block placement. So it shares the same UI now too and the same entry points. While doing that, I noticed that block handling in context module is still crap and does not use hook_block_list_alter() but hook_page_build() instead. Due to that, some conditions like "sidewide" context which ironically are checked in hook_page_build() too are fired AFTER hook_omega_layout_alter() (which is fired in omega_block_list_alter()) can never trigger the layout change. Hmmmmmmmmm.... :/

Well, but the .js works :P

attiks’s picture

Status: Needs review » Fixed

Nice work, I only add one line to change the title of the reaction so people can easily find it.

attiks’s picture

follow up created for sitewide context: #2001898: Sitewide context isn't working

fubhy’s picture

Priority: Normal » Critical

Looks like you didnt commit the whole thing. The JavaScript is missing and maybe more! Cant check properly currently. Am in my tablet.

fubhy’s picture

Status: Fixed » Active
attiks’s picture

Status: Active » Fixed

js added, rest should be there

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

drupalway’s picture

Status: Closed (fixed) » Needs review
StatusFileSize
new2.51 KB

There are only default regions loaded by parent options_form() function:

class context_omega_reaction_omega_layout extends context_reaction_block {

  /**
   * Options form.
   */
  function options_form($context) {
    $form = parent::options_form($context);

So if layout has additional regions, they are not shown in the list.

Could you please review the patch

drupalway’s picture

Forgot to load blocks into additional regions

drupalway’s picture

Status: Needs review » Fixed

Due to answer in this issue #2039593: Adding an extra region all regions that we are going to use in layouts have to be added to a theme info file. So please ignore my patch.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

alex.skrypnyk’s picture

Although #12 is a valid point, patch in #11 works perfectly when using multiple themes (including separate admin theme) as, as context knows only about regions from currently active theme (see epic https://drupal.org/node/316555).

This also works with context_omega module.