Revision: 29893
          http://sourceforge.net/p/bibdesk/svn/29893
Author:   hofman
Date:     2025-11-28 18:01:16 +0000 (Fri, 28 Nov 2025)
Log Message:
-----------
bind directly to view controller file owner, as this already implements 
NSEditor and NSEditorRegistration

Modified Paths:
--------------
    trunk/bibdesk/BDSKConditionController.h
    trunk/bibdesk/BDSKConditionController.m
    trunk/bibdesk/Base.lproj/BDSKCondition.xib

Modified: trunk/bibdesk/BDSKConditionController.h
===================================================================
--- trunk/bibdesk/BDSKConditionController.h     2025-11-28 16:36:00 UTC (rev 
29892)
+++ trunk/bibdesk/BDSKConditionController.h     2025-11-28 18:01:16 UTC (rev 
29893)
@@ -44,7 +44,6 @@
 @class BDSKFilterController, BDSKRatingButton;
 
 @interface BDSKConditionController : NSViewController {
-    NSObjectController *objectController;
     NSComboBox *keyComboBox;
     NSPopUpButton *comparisonPopUp;
     NSPopUpButton *attachmentComparisonPopUp;
@@ -74,7 +73,6 @@
     BOOL isObserving;
 }
 
-@property (nonatomic, nullable, strong) IBOutlet NSObjectController 
*objectController;
 @property (nonatomic, nullable, strong) IBOutlet NSComboBox *keyComboBox;
 @property (nonatomic, nullable, strong) IBOutlet NSPopUpButton 
*comparisonPopUp;
 @property (nonatomic, nullable, strong) IBOutlet NSPopUpButton 
*attachmentComparisonPopUp;

Modified: trunk/bibdesk/BDSKConditionController.m
===================================================================
--- trunk/bibdesk/BDSKConditionController.m     2025-11-28 16:36:00 UTC (rev 
29892)
+++ trunk/bibdesk/BDSKConditionController.m     2025-11-28 18:01:16 UTC (rev 
29893)
@@ -61,7 +61,7 @@
 
 @implementation BDSKConditionController
 
-@synthesize objectController, keyComboBox, comparisonPopUp, 
attachmentComparisonPopUp, dateComparisonPopUp, valueTextField, countTextField, 
numberTextField, andNumberTextField, dateTextField, toDateTextField, agoText, 
periodPopUp, booleanButton, triStateButton, ratingButton, colorWell, 
comparisonView, valueView, addButton, removeButton, heightConstraint, 
comparisonWidthConstraint, valueWidthConstraint, stringvalueWidthConstraint, 
filterController, keys;
+@synthesize keyComboBox, comparisonPopUp, attachmentComparisonPopUp, 
dateComparisonPopUp, valueTextField, countTextField, numberTextField, 
andNumberTextField, dateTextField, toDateTextField, agoText, periodPopUp, 
booleanButton, triStateButton, ratingButton, colorWell, comparisonView, 
valueView, addButton, removeButton, heightConstraint, 
comparisonWidthConstraint, valueWidthConstraint, stringvalueWidthConstraint, 
filterController, keys;
 @dynamic condition;
 
 + (void)initialize

Modified: trunk/bibdesk/Base.lproj/BDSKCondition.xib
===================================================================
--- trunk/bibdesk/Base.lproj/BDSKCondition.xib  2025-11-28 16:36:00 UTC (rev 
29892)
+++ trunk/bibdesk/Base.lproj/BDSKCondition.xib  2025-11-28 18:01:16 UTC (rev 
29893)
@@ -23,7 +23,6 @@
                 <outlet property="heightConstraint" destination="uJt-lu-0lf" 
id="9ZR-au-Bhd"/>
                 <outlet property="keyComboBox" destination="272" id="285"/>
                 <outlet property="numberTextField" destination="185" id="242"/>
-                <outlet property="objectController" destination="403" 
id="431"/>
                 <outlet property="periodPopUp" destination="188" id="244"/>
                 <outlet property="ratingButton" destination="320" id="321"/>
                 <outlet property="removeButton" destination="270" id="288"/>
@@ -63,7 +62,7 @@
                                 </menu>
                             </popUpButtonCell>
                             <connections>
-                                <binding destination="403" name="selectedTag" 
keyPath="selection.attachmentComparison" id="407"/>
+                                <binding destination="-2" name="selectedTag" 
keyPath="representedObject.attachmentComparison" id="yiT-ja-NHF"/>
                             </connections>
                         </popUpButton>
                     </subviews>
@@ -90,22 +89,22 @@
                                         <menuItem title="does not contain 
part" tag="1" id="232"/>
                                         <menuItem title="contains" tag="2" 
id="234">
                                             <connections>
-                                                <binding destination="403" 
name="enabled" keyPath="selection.stringCondition" id="24g-iB-xap"/>
+                                                <binding destination="-2" 
name="enabled" keyPath="representedObject.stringCondition" id="78u-0B-S9h"/>
                                             </connections>
                                         </menuItem>
                                         <menuItem title="does not contain" 
tag="3" id="228">
                                             <connections>
-                                                <binding destination="403" 
name="enabled" keyPath="selection.stringCondition" id="Ig1-gD-uYL"/>
+                                                <binding destination="-2" 
name="enabled" keyPath="representedObject.stringCondition" id="ohc-bq-pNm"/>
                                             </connections>
                                         </menuItem>
                                         <menuItem title="starts with" tag="6" 
id="227">
                                             <connections>
-                                                <binding destination="403" 
name="enabled" keyPath="selection.stringCondition" id="YhR-vw-kDr"/>
+                                                <binding destination="-2" 
name="enabled" keyPath="representedObject.stringCondition" id="fyW-wu-eDL"/>
                                             </connections>
                                         </menuItem>
                                         <menuItem title="ends with" tag="7" 
id="229">
                                             <connections>
-                                                <binding destination="403" 
name="enabled" keyPath="selection.stringCondition" id="Hne-QV-ro1"/>
+                                                <binding destination="-2" 
name="enabled" keyPath="representedObject.stringCondition" id="y5K-hh-GRo"/>
                                             </connections>
                                         </menuItem>
                                         <menuItem title="comes before" tag="8" 
id="230"/>
@@ -114,7 +113,7 @@
                                 </menu>
                             </popUpButtonCell>
                             <connections>
-                                <binding destination="403" name="selectedTag" 
keyPath="selection.stringComparison" id="405"/>
+                                <binding destination="-2" name="selectedTag" 
keyPath="representedObject.stringComparison" id="2yA-Ri-876"/>
                             </connections>
                         </popUpButton>
                     </subviews>
@@ -158,7 +157,7 @@
                                 </menu>
                             </popUpButtonCell>
                             <connections>
-                                <binding destination="403" name="selectedTag" 
keyPath="selection.dateComparison" id="409"/>
+                                <binding destination="-2" name="selectedTag" 
keyPath="representedObject.dateComparison" id="2tp-Ua-V9f"/>
                             </connections>
                         </popUpButton>
                     </subviews>
@@ -207,7 +206,7 @@
                                 <color key="backgroundColor" 
name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
                             </textFieldCell>
                             <connections>
-                                <binding destination="403" name="value" 
keyPath="selection.countValue" id="413"/>
+                                <binding destination="-2" name="value" 
keyPath="representedObject.countValue" id="ROq-p3-4eS"/>
                             </connections>
                         </textField>
                     </subviews>
@@ -246,7 +245,7 @@
                             <rect key="frame" x="4" y="5" width="178" 
height="22"/>
                             <color key="color" red="0.05813049898" 
green="0.055541899059999997" blue="1" alpha="1" colorSpace="calibratedRGB"/>
                             <connections>
-                                <binding destination="403" name="value" 
keyPath="selection.stringValue" id="Tzk-cI-cty">
+                                <binding destination="-2" name="value" 
keyPath="representedObject.stringValue" id="dRe-gq-Qrs">
                                     <dictionary key="options">
                                         <string 
key="NSValueTransformerName">BDSKColorFromString</string>
                                     </dictionary>
@@ -271,7 +270,7 @@
                                 <font key="font" metaFont="cellTitle"/>
                             </buttonCell>
                             <connections>
-                                <binding destination="403" name="value" 
keyPath="selection.stringValue" id="458">
+                                <binding destination="-2" name="value" 
keyPath="representedObject.stringValue" id="H3g-XM-FNO">
                                     <dictionary key="options">
                                         <string 
key="NSValueTransformerName">BDSKTriStateFromString</string>
                                     </dictionary>
@@ -296,7 +295,7 @@
                                 <font key="font" metaFont="cellTitle"/>
                             </buttonCell>
                             <connections>
-                                <binding destination="403" name="value" 
keyPath="selection.stringValue" id="457">
+                                <binding destination="-2" name="value" 
keyPath="representedObject.stringValue" id="eXY-UC-BA4">
                                     <dictionary key="options">
                                         <string 
key="NSValueTransformerName">BDSKBooleanFromString</string>
                                     </dictionary>
@@ -322,7 +321,7 @@
                                 <color key="backgroundColor" 
name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
                             </textFieldCell>
                             <connections>
-                                <binding destination="403" name="value" 
keyPath="selection.stringValue" id="411"/>
+                                <binding destination="-2" name="value" 
keyPath="representedObject.stringValue" id="RZc-Kc-8NA"/>
                             </connections>
                         </textField>
                     </subviews>
@@ -360,7 +359,7 @@
                                         <color key="backgroundColor" 
name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
                                     </textFieldCell>
                                     <connections>
-                                        <binding destination="403" 
name="value" keyPath="selection.toDateValue" id="423"/>
+                                        <binding destination="-2" name="value" 
keyPath="representedObject.toDateValue" id="YM8-np-ggo"/>
                                     </connections>
                                 </textField>
                             </subviews>
@@ -388,7 +387,7 @@
                                         <color key="backgroundColor" 
name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
                                     </textFieldCell>
                                     <connections>
-                                        <binding destination="403" 
name="value" keyPath="selection.dateValue" id="421"/>
+                                        <binding destination="-2" name="value" 
keyPath="representedObject.dateValue" id="NK2-uU-SsK"/>
                                     </connections>
                                 </textField>
                             </subviews>
@@ -433,7 +432,7 @@
                                         <color key="backgroundColor" 
name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
                                     </textFieldCell>
                                     <connections>
-                                        <binding destination="403" 
name="value" keyPath="selection.numberValue" id="415"/>
+                                        <binding destination="-2" name="value" 
keyPath="representedObject.numberValue" id="jaq-x7-XUF"/>
                                     </connections>
                                 </textField>
                             </subviews>
@@ -462,7 +461,7 @@
                                         </menu>
                                     </popUpButtonCell>
                                     <connections>
-                                        <binding destination="403" 
name="selectedTag" keyPath="selection.periodValue" id="419"/>
+                                        <binding destination="-2" 
name="selectedTag" keyPath="representedObject.periodValue" id="6G3-CZ-TBq"/>
                                     </connections>
                                 </popUpButton>
                             </subviews>
@@ -513,7 +512,7 @@
                                         <color key="backgroundColor" 
name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
                                     </textFieldCell>
                                     <connections>
-                                        <binding destination="403" 
name="value" keyPath="selection.andNumberValue" id="417"/>
+                                        <binding destination="-2" name="value" 
keyPath="representedObject.andNumberValue" id="Ccc-On-nhP"/>
                                     </connections>
                                 </textField>
                                 <textField horizontalHuggingPriority="750" 
verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" 
id="181">
@@ -578,24 +577,6 @@
             </constraints>
             <point key="canvasLocation" x="66.5" y="150"/>
         </customView>
-        <objectController id="403" userLabel="Object Controller">
-            <declaredKeys>
-                <mutableString>stringComparison</mutableString>
-                <mutableString>attachmentComparison</mutableString>
-                <mutableString>dateComparison</mutableString>
-                <mutableString>stringValue</mutableString>
-                <mutableString>countValue</mutableString>
-                <mutableString>numberValue</mutableString>
-                <mutableString>andNumberValue</mutableString>
-                <mutableString>periodValue</mutableString>
-                <mutableString>dateValue</mutableString>
-                <mutableString>toDateValue</mutableString>
-                <mutableString>key</mutableString>
-            </declaredKeys>
-            <connections>
-                <binding destination="-2" name="contentObject" 
keyPath="condition" id="430"/>
-            </connections>
-        </objectController>
         <customView translatesAutoresizingMaskIntoConstraints="NO" 
id="1Np-fm-P1q" userLabel="View">
             <rect key="frame" x="0.0" y="0.0" width="639" height="32"/>
             <subviews>
@@ -612,7 +593,7 @@
                             </dictionary>
                         </binding>
                         <binding destination="-2" name="enabled" 
keyPath="filterController.hasMultipleConditions" id="Y5g-N1-RJs"/>
-                        <binding destination="403" name="hidden" 
keyPath="selection.self" previousBinding="Y5g-N1-RJs" id="IRl-h6-e8g">
+                        <binding destination="-2" name="hidden" 
keyPath="representedObject" previousBinding="Y5g-N1-RJs" id="p6j-9f-AqN">
                             <dictionary key="options">
                                 <string 
key="NSValueTransformerName">NSIsNil</string>
                             </dictionary>
@@ -655,13 +636,13 @@
                         <color key="backgroundColor" 
name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
                     </comboBoxCell>
                     <connections>
-                        <binding destination="-2" name="contentValues" 
keyPath="keys" id="278"/>
-                        <binding destination="403" name="value" 
keyPath="selection.key" previousBinding="278" id="429"/>
-                        <binding destination="403" name="hidden" 
keyPath="selection.self" id="DT9-6a-Cel">
+                        <binding destination="-2" name="hidden" 
keyPath="representedObject" id="HZB-Ds-rJG">
                             <dictionary key="options">
                                 <string 
key="NSValueTransformerName">NSIsNil</string>
                             </dictionary>
                         </binding>
+                        <binding destination="-2" name="contentValues" 
keyPath="keys" id="278"/>
+                        <binding destination="-2" name="value" 
keyPath="representedObject.key" previousBinding="278" id="wUW-G1-Keo"/>
                     </connections>
                 </comboBox>
                 <customView translatesAutoresizingMaskIntoConstraints="NO" 
id="0gC-VL-mI4">
@@ -671,7 +652,7 @@
                         <constraint firstAttribute="width" constant="192" 
id="YRk-AL-o36"/>
                     </constraints>
                     <connections>
-                        <binding destination="403" name="hidden" 
keyPath="selection.self" id="P4C-9t-oBj">
+                        <binding destination="-2" name="hidden" 
keyPath="representedObject" id="dy4-gO-Vyn">
                             <dictionary key="options">
                                 <string 
key="NSValueTransformerName">NSIsNil</string>
                             </dictionary>
@@ -685,7 +666,7 @@
                         <constraint firstAttribute="width" constant="240" 
id="khh-IA-HtI"/>
                     </constraints>
                     <connections>
-                        <binding destination="403" name="hidden" 
keyPath="selection.self" id="p12-UK-cuz">
+                        <binding destination="-2" name="hidden" 
keyPath="representedObject" id="uAl-I9-rO2">
                             <dictionary key="options">
                                 <string 
key="NSValueTransformerName">NSIsNil</string>
                             </dictionary>

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.



_______________________________________________
Bibdesk-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bibdesk-commit

Reply via email to