Commits

Max Seelemann  committed 40ed0c2

Added support for non-selectable view-based toolbar items

  • Participants
  • Parent commits 03abd8a

Comments (0)

Files changed (1)

File BWSelectableToolbar.m

 	
 	for (currentItem in [self items]) 
 	{
-		[currentItem setTarget:self];
-		[currentItem setAction:@selector(toggleActiveView:)];
+		if ([currentItem view]) {
+			[currentItem setTarget:nil];
+			[currentItem setAction:nil];
+		} else {
+			[currentItem setTarget:self];
+			[currentItem setAction:@selector(toggleActiveView:)];
+		}
 	}
 }