     //--------------------------------------------------------------------------
 
     private function defaultButtonBarItemRendererFunction(data:Object):IFactory
-	{
-		var i:int = dataProvider.getItemIndex(data);
-		if (i == 0)
-			return firstButton ? firstButton : middleButton;
-
-		var n:int = dataProvider.length - 1;
-		if (i == n)
-			return lastButton ? lastButton : middleButton;
-
-		return middleButton;
-	}
+    {
+        var i:int = dataProvider.getItemIndex(data);
+        if (i == 0)
+            return firstButton ? firstButton : middleButton;
+
+        var n:int = dataProvider.length - 1;
+        if (i == n)
+            return lastButton ? lastButton : middleButton;
+
+        return middleButton;
+    }
 
     
     //--------------------------------------------------------------------------

        var index:int = dataGroup.getElementIndex(
                            event.currentTarget as IVisualElement);

		if (index == selectedIndex)
		{
			if (!requiresSelection)
				selectedIndex = -1;
		}
		else
		{
			focusedIndex = selectedIndex = index;
		}
    }
    
    /**
     *  @private
	 *  Attempt to lift the focused button above the others
	 *  so that the focus ring can show.
     */
    private function adjustLayering(focusedIndex:int):void
    {
		var n:int = dataProvider.length;
		for (var i:int = 0; i < n; i++)
		{
			var renderer:IVisualElement = IVisualElement(dataGroup.getElementAt(i));
			if (i == focusedIndex)
				renderer.layer = 1;
			else
				renderer.layer = 0;
		}
	}

    /**
     *  @private
     */
    private function buttonBar_keyDownHandler(event:KeyboardEvent):void
    {
		var currentRenderer:IItemRenderer;
		var renderer:IItemRenderer;
		
		if (event.eventPhase == EventPhase.BUBBLING_PHASE)
			return;

		if (!enabled)
			return;

        switch (event.keyCode)
        {
            case Keyboard.UP:
            case Keyboard.LEFT:
            {
				currentRenderer = dataGroup.getElementAt(focusedIndex) as IItemRenderer;
				if (focusedIndex > 0)
				{
					if (currentRenderer)
						currentRenderer.showFocusIndicator = false;
					--focusedIndex;
					adjustLayering(focusedIndex);
					renderer = dataGroup.getElementAt(focusedIndex) as IItemRenderer;
					if (renderer)
						renderer.showFocusIndicator = true;
				}

                event.stopPropagation();
                break;

        if (dataProvider)
            dataProvider.removeEventListener(CollectionEvent.COLLECTION_CHANGE, resetCollectionChangeHandler);
    
        // not really a default handler, we just want it to run after the datagroup
        if (value)
            value.addEventListener(CollectionEvent.COLLECTION_CHANGE, resetCollectionChangeHandler, false, EventPriority.DEFAULT_HANDLER);

