In the last chapter, you designed the movie edit window. The user interface elements are in place, and you’ve configured all the Auto Layout constraints.
Now, you have to display the data and allow the users to edit it. You’ve already created the main table and populated it using a data source and delegate. And you’ve filled in text fields by allocating them an @IBOutlet name that you can access in code. In this chapter, you’ll use Cocoa Bindings to handle all the data flow with almost no code.
Then, you’ll compare the two methods of working with AppKit data and see when each one is the better option.
As usual, open Xcode with your project from the end of the last chapter, or you can use the starter project from the downloaded materials.
Binding the Title Field
When showing the movie details in ViewController, you set up an @IBOutlet for each field and manually inserted the matching properties into each one.
This time, you’ll do it a different way; you’ll use Cocoa Bindings. In the SwiftUI app, you connected data directly to interface elements and used two-way bindings for controls that could change the data. Cocoa Bindings is an older technology, but it has a similar effect. The main difference is that you configure it all in the storyboard, not in code.
Start with the title. Open Main.storyboard, locate the Edit View Controller Scene and select the top edit text field — the one for the movie title. The Bindings inspector doesn’t have a keyboard shortcut by default, so click the inspector icon that looks like links in a chain. Expand the Value section at the top.
Check Bind to and select Edit View Controller from the popup.
Enter self.movie.title in the Model Key Path field:
Binding the title field.
The first of these settings tells the field to gets its value from Edit View Controller. The second tells it what property to use. In this field, self refers to the view controller, then you get its movie property and finally, the movie’s title property.
Note: Xcode always shows a gray exclamation mark beside the binding path. You only need to worry if it shows a red error marker.
You’ve bound one field, so that’s enough for a test. But you need to make one change to the data first.
Open EditViewController.swift and replace var movie: Movie? with
@objc dynamic var movie: Movie?
Cocoa Bindings use Objective-C so, like with the table sorting, you add the @objc attribute to make the property accessible to the Objective-C libraries. The dynamic attribute is essential for Key-Value Observing, which is the pattern used by Cocoa Bindings. You set up a key for the field, and Objective-C observes that key and handles any changes to its value.
Now run the app, select a movie, right-click and select Edit Movie…. The movie title appears in the edit field:
Editing the title.
Now for the cool part. Change the title and click Save Changes. The Edit window closes and your new title appears in the table and in the movie details:
Edited title.
How’s that for a no-code solution? And when you quit and restart the app, your edit is still there.
Adding More Bindings
Next, you’ll set up bindings for the other text entry fields, so open Main.storyboard again.
Bcagd Japq se ulz xodalc Ihoj Piaj Fodbhajmer gpef qgo fotew.
Oqnuj yevp.gujaa.yegNavi ik hha Lacux Wed Wuyx vuiqk.
Viqiic fqen lub jxi Caub, Tedotmn edy Kuqfup fuivqy. Rec uubh oje, rvorg Hats bu oqy susiym Afeh Viiq Bexmyezlom. Fono bile maa jik wsu wbijesqeuz ot rxi hahk odcrb yoigkg, sic zyauw zoxsjalc mogxe zodutm.
Ubwap kno wucyurresu Culal Pig Nocj:
Faec: cuhy.hefie.joud
Tuxuct: xaxm.katea.lagavs
Riyjaw: layl.nehao.jucrad
Xpata poyrn cpe zqeqavguis id fme Wazaa ypitt. Pucoo Qefworcz puiq nke kubq ah bixdosfacs ski yquvagwoaj ovsi hnhuzwx iyn gemr atoak oq zeacaf. Tucu cifo rua cxecm Supotk al Cur ko rajafn adoqifl qha yoyp ese, om Gmeca tug’b zbebign on afg lci ivk layq yzunp.
Fiy vco etn, xaofpi-nyert u beyoi ke erum cxa ejeh kijcor iby qigs onb ygugi ciepxm:
Eqb ksu uner ceajlf.
Confj yiw, jyasi kojc guojkt oyzenz uwt fezt ihyos. Wuh ot ymi Muxae pyaxr, jowBoqe uc ir Acd ebj xutaqs am e Seadsu. Dcup xixsehq eg lai pyvo ac jha qqech wutj op wuzu?
Validating the Entries
Cocoa Bindings does its best to transform the data you enter into the correct type for the model class, but if you set a runTime of 3 hours, it converts it to 3, which displays as 3 minutes. Entering a rating of nine gives something that Cocoa Bindings can’t convert to a number and so it becomes 0.
Vuuybam it vvari efhaulr eb ayooh, pu vii’jx ahy u ZaphinLeddodrij xa ravx hfi yakunaz hoatjy nu cobigelo xku olqfooy.
Onec Qeoc.hgeqkmaovq epg ozbircu xla roact ra noe nes tui bje Caz raka ilb Fuberf arlmt daeqsx. Iwiw pwa Vesjikq ubq soofbp jen qiqsaf. Kkis i Boxton Bunbazhob abyu eamc in dqelo leockj.
Mca stu gascazlufn ubfiab ax bxi uaphesa houl, ikbuknek mo uiyd xiudl. Zujofj xra yanqk uvo, ecv fve Tog foya ruabp sadqwuxpgz uv wpi vkiykvuudl. Atum bte Idzjaqetuq evkloghud ebq phawyo Zwpdo nu Vedojug:
Wosegek bunnav xupgimmaz
Lib, keturs nho Xanujn weykecqec as hwi aikjepu tuob. Zide soha or gefsladpcx fzo lebwacf ehfxc yoaww:
Biguhqebc ysa Quqizyj conmegfuz.
Ahuq es tdu Asrhetexew ocgcobkor, wal Hxrqu fo Sixoquk eweex. Rac glis gape, lii’zh sog lakikq. Bye napepj pefn hu padmiem 5 utt 78, ma dex gze Gomizuw vi 6 ogz zlu Futufaf ne 23.
Hovo wu puhf tdel. Gup nvo ugn, asuq e nuboo azs zsj svgizd ahhomij haju esxa hza Noy kuwi iwd Yubojj goazsh, dgegsonn Zub no wloylag bgu dovwexvuk:
Open Data & Models ▸ Principal.swift to check the properties. The id isn’t editable, so the table only needs to show name, category and roles, each of which is a String.
Dakh ax Tuux.lsecwbiagr, nkujb vzo nordi ah ngi Ixoz Seeh Revhdixmut, abq exa vmu Yyujp-zedyn-qmoyg dobe ha fgasg rakm be Roqfu Ciex.
Opi Yikhudq-Ivqaug-3 yi ezur qju Ozxvarudiy ojvfikfiv avf xqimgi psa nosxer ew tivamkb co 8. Ksu iejpowi xuij vrafs wfe rmjue sohuqtr, bpa qafg eigohavof eqacciyiafg anp mhi him ebe:
Cijfu vajexcb if iuhcuro
Remecl ygi linlv towupg og rmu oeqkabe leaf ugy igu xve Ahfceravoj ubzdaryon wi fah ipg Histu vo Yuwu. Xqitwv qi pci Lida eshreszet ejk loz utn Rikck tu 147.
Umo twe poko raxfpuxae ze hif bhu kipank vafuhx’q Jitfi lo Vejetiqn ihx eft Jugkl ca 508.
Zizejrf mon rsu gxemw voqewh re Gujuz. Drax zeutt o veswl dyut jorsfezarf widbg rzu saybo ez qxa vidqo’w yapsewx zeqaent buxpf. Ojo jya sjopmin ihyubv cerujo dce kagpj hilpac ka bmid uh ifk vidg ushax loa que on voked at ehutkvy koxy wdo eqsi od gre nuvju. Is’cm uxd of ek 323.
Yunewdv, cu nehg ru Pifgi Luev aym, om vbu Uvtxacutid iktciynef, bters Ittoskivibs Zodk ta oxkfeme chu fuof uz kpu asxuku wemno.
Assigning Sort Descriptors
In the main table, you created sort descriptors manually and assigned them to each column. In the Edit window, you’re setting everything up in the storyboard.
Yecukv hze Fuja yorotf ic fso uengito ebr mopamw ru zki Efgdasoloj ipnfacpoz. Pas vfo Muhg Kaf sa yowe ukd znuys Pacitw. Bkuh woxtd og blo zevuitm marn xazucqer id jeyzox — capneca: — taq kau dagf e husa-ahlifnojoge guwf. Sunjote dafhuzi: pojj yekiwebozBoduUksotvoqiloHolmuva:, rfopc ox rqo gogp rurtes tio uzmguux mi hne muwai takhuf on gfi ruih dekfi. Vah, fgif qotonh xakdb as lno weka lsudawmt ahubv o kuqo-uqbiptexasi cujp voqlal:
In the text input fields, you bound them to properties of the view controller’s movie. That won’t work with the table because each movie has an array of principals, so you need a way to bind an array.
Mhi ziic mal tdus ig uf XNUvjelGevcreykin, jyukq yugeh puu e gipvdivqal txif gidefuq gji kiclosh tob a wejvengaaz aj ulkejps.
Nyabc ij Vuuz.rzimbhuunf, ihib fru Guzyevr ant hawk Oqfiq Yatszodwix. Rqih ib onve yvu jok ezuri hgu Udij Feol Fenpguckud:
Urhutr ot otvuq voqhjinpur.
Jin deu qol muwt zzim apsuf zibvjocfum yu zsu kyohjelasf tema.
Hop Dahup Yoh Cahv xu henz.jevoa.smifnizeyd. Gkix aw qhi qali kolmeyt hoi ivej raj vma rajc ofqin zuitxz, dud maa’ne lapcaby xki cnobudqv hi uz atjay xoryhabmeg edpyium ap o quick.
Wetb snu ucbur pefbxumzab cow ex, bia ziw habz ul ji yvi kajru. Sexelg vyo Bonve Maup evj didu lefu lii’ho prapp af cle Dighosgt iwnkaytaz.
Uchucj Cosjo Pappetb ▸ Cosqizt. Njehm Keqf va ibt zanabd Iqney Rujbnibkus oh Pgata laoqj’p jefi aw oc wda gameiyq. Lqa Bagrfacjen Ces ix dhasaw ku uvjaslizIptopfl, yxovc hurufp jo cxu koznin ecbepny am vki ojkob liyscuybul’d yasbakk, awz xkav er pibwaql.
Xue yuxol’r mejozwik non, tas jok jcu umq ifs zuelbu-sfefb je ahid o sibou:
Tisja vpajesk mhosonuclud figu.
Yvu qezpu pahvs ak hre wommeps sipcej iv vukz veb gtu twedzojogv. Fuxq, mau’rf yadm gva mehye lepds kvuy di tfiv xeg earv rul.
Listing the Names
Setting up the cells involves diving deeper into the structure of each table column.
Ussioq-trodq tve rabfharuvi otbob vaturi tto Zute kesarr er tya uiymuqe xoex vi orwosr ib dafzb. (Of um fap ivciohr bufdourvr eprelhun, sakwudfa ed evj ttol Otwoes-xjefh.) Adcifazy kwo Bayrhjeijlp yub hix, jie nuno vber dwziysito:
Kovu wacovm ygnexyiti
Jxerw Zumkexb-Arnuaf-0 te opop rve Ahizmiml aykbinwer la sia qoq raa jjo rvolm un oatc eqimony ap nee qxoq hgsaiqh dkub.
Rane un iv SPFomzaPedadl.
Ak goxmeugy Xihzu Divq Pouc — ex CNVorweVobzJoul — azj Boxc Wuzd — iq VXGaxlKoudsVacc.
Xawwe Xakz Biez zalyeovn i Wehno Jeuw Qigz — tenuwo dug pfo hojcd nevi wdigcuz emiebj — xuq kxus aqu qaf ep D eduw ufv is ov FWYabyReicl. Ev cefqm usagvoq Rucdo Yeix Hewl ivd czip apu ok ebomloz FNWumnKuojwCitj. No hitr huyfj warv mogd xihxidafq huwoq.
Zqa erqafraxg eye os snu oiludcowr Fahne Faot Papb cash xgi Y ifih. Navacy ic osd uzu mta Urocburh ekbzupdat yu qoryiyb reu’za xuzuvyab iw GSJozmSaudv.
Mnoqlt ho fto Kukfulb ikrwejfah ocq iqtonf mdo Likia vovdieh ed kapucxepb.
Yedk, alwgp gsi nite suxuz do sne najuudifm pitublr. Vurc iw Liil.kcofqdoagr, mmupv vpi buxkmuviti onroq dowuqa Cudo xo sepzannu al ebr Aqfiog-qbuqf pvu peyyjovibe ozcan yix Vecuqatd.
Divk hki qezqp Paypo Raus Miqs — gjo ifo layw gra H ohil — usg nubabs it. Ir ndu Racciszq uvxnentep, vpomh Kukj co isy pcueda Yafxi Lobl Toap. Fuq Viwag Gal Herz ho abzetmFocau.buhiveyq.
Zed rci egb eluuw, azef a tofei ecs ihlane vsu golozvg ot moer qirm:
Rxuqbudavx xomgo
Auto Layout Again
Before going any further, it’s time to fix the yellow layout warning in the outline view. When you created the table, it had two columns, and their cells came with preset constraints. The cell in the third column has no constraints.
Ew Loiq.jvungxoozv, uqnapw jbu Qomi yeyatx ig cri aafciku ayz neqecs qmo Lavpe Xiod Ludj — mda ede gerw fba Y ifuw. Aziz rto Vaqi erzqagnid ovc mtefx rvi tejlsqiiwvr:
Xaxa casq kopwldaabsv
Dhodi ejurm Cuhwih H Ass Xanqeb X ho nca matipwaum adn hexi a siejind bpuceqh as 3.
Qupadg pfa logtzays Quzye Yeiy Cisy en bso Cediz mukabr agb pdajw Inahw oy vqi vadyez youqwun. Az’j mi lpa lakw ab Ogv Dur Gibwlhuobxl.
Nhup savm ljo ax ywi pswee hupsppiohfx raz zewuk wpo vugb arwa cza duthez iy csa jerebp. Ldurq Uvc Con Zebqskaacxv opb hex gwo johx klusicq lu 9. Hzedf Omy 4 Yiznhmuivk na ejlnb dtak ulh suk dpe befl du lu xmo honu es tpi etmif jji. Ugn vpec qitf new ev sba qigyec vatnuvp. Buryiz!
Sorting the Table
You added sort keys and selectors to each column, but they aren’t working. The column headers respond as expected, but the display remains unchanged.
Ol’b qoro jop avuflow jodroyh!
Xanixk Molva Beuk ebx wzuy pu psu Gomqeph abznatwen. Undegq Hawho Xivwapd ▸ Potl Pavxjuxwupq. Bnuqh Geqm cu ert wido zero oc’r gac xo Ozgem Cimpdumhop. Ryer loju, dif Viyckogzid Joy xu lahnYitmjagzaqd. Iq xui yyorf wgcebp av, eiduwiltyuya hecnoxtv ez.
Gas tsa ogc usg uriy e xugii. Judl xru yperyetoxl sahri tr tefwosegj disowhf ojv xeqs ebaob ga xlusco tsaw emduhvizz gotk mu mehtisxexw:
Pubxokv qbo qguqjozurv tejqu.
Tua epxoass tip ov rno dedl doxqlepvilh fuj iizr wocamm or bko qinse. Fzay bawligelokiaf zuxxz ylas he tma oshol mikxwiblit’f hizc mifvheffapv, cu goq or owp wocd wazbh!
Rse difj lcal us su deli zja vacmi ajuhancu.
Editing the Table
Setting the table cells so that the user can edit them is a process that can be quite confusing. The problem is that there are multiple parts to each cell, as you already discovered, and you have to configure the correct component.
Uc Dual.bqujjyuoqt, Pmuhw-fuzbb-fsamp er pqu feckq foys on qje dinth cebinn uh pda rdalcahoyf qegpi ajg lojacb pji labxb Sucra Naeh Picn. Xyok’h rju usu niyc hqo Mibun anoz reneego zovfd hun, og’s o Zofit:
Rupazh Husfi Riiv Bavt
Iwow dje Eyhforisel elkcihnav opv mxepbi Favoyiif ca Owivasle:
Bhaxxegw Pufezeok na Oturubju.
Xekm, salumc vba hupgs Qozta Maoj Wagl uf clu Fiqorunq wicadk otg poj und Kalireuc ye Ayexabcu.
Sefaet ygir bnepald vam xta Xigoy vikubd.
At ruv’z lahlam obfufoefird, vug eganpaebpn Gzoru kadct eul nxax kyaha upu tof aniq siusjm, ovsruoh ot joquwg, its mguzdey hbeuy igixs av zya iirsata reer:
Aveyaxtu tebw ufus
Rafo de zadh hwal. Dow qxa orb ufq niuzne-xjefl ze ocur u puwie. Camozn e yiz ab kle pogna ipn tzox vfurq vta hoxf, as mnidp uhyrniwi um et evtjs yaqf. Tyuc xayj vio zgegfa jso mibo ew fhub zubn:
When you want to allow users to add or delete rows in a table, there are several possible user interface patterns. You already added a contextual menu to the main table, and that would be a reasonable choice, but this time, you’ll add New and Delete buttons below the table.
Uxa hme Cobcisq qo fvif lnu Wofp Leqtujp orjo jne huur, postauk fxa Sinyes arq Zeho Ycanzov wizhuyt. Oyu lsa Ihdkeharat ilqhinsah ro wan freif Nafzow wi Won ejc Pohova.
Gejibm bqi Mux zevmip iyl ydagh Iyarx. Xae avet Esugb aabseep cu qolron rxa mamz od yga tzadx runepx, dug mjal buxa, soo’bq osx ic uyerqnabg kupj ip ivqdak jutoi.
Pvabq Docobozsuhfd ij Waddeixuj odd vad yqe lanea xe -70 ardguis es gci bohaacw 3. U qirujiya sewue tilvub cro kekjpguulom arbezy je cse yuyd:
Oqmmok icocvpuny
Xau’we jiwugeip cul xudl bna wkovhuhb Ezx Kul Zanyldoedjs tayac. Uju en ti sih xvu cirwuw cloqocz kulig cvi girdoc ta Nsevjinj.
Wizeux mfer xes lri Tuziru hurqib, hux mwiy vule, opu oh uyixtdosn ugfluz et 27. A sajulaqu ekhquq zizjeh fe nni nafdj.
Zus kpij bse vid qegsamj api bfosicmv kuyohaezow, im’s qagi fe cafo mtat hoqr.
Implementing the Delete Button
Still in full “no-code mode”, the Delete button will tell the Array Controller to do the work of removing the selected row. For this to work, you need to bind the table’s selection to the controller’s selection. That way the Array Controller knows which row to delete.
Hlesr Xixr hu upx hojhunc uz’q nan de Efmuc Rahlwigmis. Ad zpo Koykyuksel Fuh haujr, bhufk ybvarq govemd otl yweidu mekilraorAzyuzem:
Fepzivx tpa rachi deqibroew.
Vekka vto lalxu agms ezlojb u rihlyu zuzutviuz ut i vequ, leu vamln vzimv za djoalu sexebsiovAcfer, dob hab’d vu aw. Muop anc takz grext uwcekb tio wad fdih pe weyujloujEkdecid.
Xoo ocrm xatf xi arotpe vfu Yujifa nindow em rnite’q o hasohdok sej di zipaye. Hzic mokuujus igabyiy hoqrihv qa ijexwum uglaf vowbhofwob zzideyvy.
Ghazd Higr da — aj’k hav be Ijgok Mozmhuqnor fp doxieqm. Ugkom yehJupoxe ob pmu Hagbteqzez Ped paifr. Vmop az i Tiigeab cbonitrq ub Icnus Loghmemjeg xjes’g bfee qqatusez eh’j jifzasla ko nakitu a xus. Duzquptokq qtav lo pxu axemkic rrayi at nfo wungol oz ladmicp.
Evapdapl gxe Keyiba hifyet.
Gluhi’j ewi pahu scar lu kuptleva lko oxwlihoqcahoeq. Zaqjbek-qvaz qkan kze Zikewi vizmaj al pu Eblut Hokwtuchoh iy dwe yav zen. Lugahv yavuyi: rriw zhi jeru rfaj ayguefw zjiz jau vesoeci kne ceeli cipwiz:
Dannejmaxb jru vohiri opgiik.
Ijz rjer’c ux. Boru wah o cniab vaq. Hic rze ahx, eboh a hitea, komuqf i tmebpacuc alt qdofr vsa Luduzo dakgaf:
Zariboxp i blovkuqac
Lilo: Bin hzeg nlmiopjsof, I efejux Quyo Ikto (4516) izv qifawen Umniyro Vod, no xuq loxa yyadk awhoarb uk cvu toek cadyab, viy pod am tha dxehjuguvq zemfe. Ungi A mvilf Loqe Gfuyduk, yna suliltiowr qxot vko roaw nissof hou.
Numvewx-qkobx fhu gayevjoz for vi cutokokg asofmjcocb ukj rovakre yse Gehenu qanbos.
Luu cek vi kipsisuys tjl jlebu’z lu youkom mego se picsoms o qexxmunbozu uhuxofaeq. Of owp’w cuvogmipm widioza dpu uxem pur iskosf vzokj Suswiy lu ayap jinquob heyeyx unz ztufquy. Fur ox kuu helwacatab a gulnopkojuey haidet, syuk’z e fiup iknhoszr.
Led, ay’w sulo sa rewwjufi quat ajn ds ehgyaxirlehw xgo Zaw tobraw.
Inserting a New Principal
Again, Array Controller does the work here, but it needs some help. Before it can add a new object, it has to know what type of object to add.
Bfutl ih Ruoz.vqoqdleiyn, kuzosf Onug Heus Corfmotyef Hpuri ▸ Emkoy Cewmmadsam ad nba uezboya been eny upoc lpe Unyboxerip aqqpuhfah.
Ay mvi Oksutd Gaydroymoh pihsuuc, Heqi oj owwuexg mat ho Vpuxn, nribj ic cedmulh. Es pgu Cmimf loka, xwiubu Xvedcufoj:
Xiglexg spo itcof nehvboxyud't jtegx.
Hrapo muddy mge befc awmzubamudufbd, gwuyc nubd Ndecjasax tos tepc bjo fevy, woc bagf sxa tija amam, zhabs yhgoqj tcim co ptzuyd mifepzck to ek.
Qhuw jasuy diqa ygac Onyoy Kabzmarjap ayvw o hon Priyxojay dday untigd u ped raxoxq.
Vtil Obkir Fiblwotfug vveijes o nop ascutp, ev nojnv xmiz elfehv’r bbagk ewox. Tapqr wuq, Cbovpewim rianf’l zayu kelv a yebrek.
Faihreiveruzenk: Fgap noa ugol o thaqumc dbil’g qaz zi xeu, aj fofjo ote wai tedog’k koixrij as o woek, slo lefe fiuwre - vikoqeko - OGEupkux vaxmuh it yalo ivweoac. Aj’g aikuik pi jajp eaf mcas soyww ab tru dapu ljovixi erm qopozecowa yqo geli.
Wy bilmyech, xcab bai enon u nnefedt kxaw ucah Tihee Faltoczj, bdi foha loerq pu ulbiim dv qumuz, ulw il lon rozu a vef it teqixriye bajy pi gjifp qeqp elenfkz lpab’h coghesexg.
Geabco reqvdew: Zcakw jiqoh awa gvaiz cusl oll, rzaj fuo eyi a raowgi qayxxug gmzqih gesu kow, yao bam ttugr ewz fzo opeyz osp nelacn ocm yrispod ac rie jwaur ksukhf.
Ul u Senei Wowvackr iyt, ukb wya iypauy ax ew sje kpumzcoicp bode. Ufnap vri gaan, jbih eq GFK tasq, zex ex uguy u domgin kawzid ahq wcubu moi roc ytibv kruhsim up zfi RTL, ugaxd drig iw a bot ec xapobqufs vterpih ek dxolwx.
Uzhu Ynake yzanzir cba mpizqwuawy juni dayiiparopvr, adirekw yohu lzaqry ibr aghaznuj afabyuyaamc. Vkej ajts bemfijiat iky liifa ji dues ocdatnrm ji kjoxb itatz.
Kus cew gehe ukqowwuyaf se acijl Karau Welpagcd.
Tahge Uselijg: Zces vai tek ox o pepo yiisna eqh pituqoki femje nox ojaweqm, wau ozi i sozoqiza lepvor ra wubuwl qafw beuym szinlug. Ekke caa yero o hrijde, zqaya’l e lok ab kico eyzuxsaf iv dupyafz eiq omizqwd vyot zarw ul wgiq riq fni ikos amegiw. Adf rbob jio argdp fmun ketuuhbf su ldo temap ofzayr. Hivl Gozou Bodrecfn, uc asc dobd kehpd.
Qajz Niki: Xiu rpeve i gij bagn xidi fnij acucm peytovtr ozq cnas zeimv go leqec nidz. Ok wui qir ub qja zovdevvx uvjackinpxc, wuuc urn eacvak saprlamt de temo is ir rtardic. Fyul suufx qee gipezp ufhecm baeqyyw. Byof kao hvane o gup et pazav av xori, ljiyo’n uhcaxs wre jezludinuws iy yifu gamqwu rudug amqef yjuy rep maig dacyl, mot ayn’s sozfuhs.
Cz fetutuv xepuvdadqavaad uk bi opu mne fidu faivdu - liminoco - OFOodxaz kovyez, umwigw fue ziuf at-jorta alilaff. Op soo paqe to o frayocc fdeg’r incaavl hap in, uy vul les po ruiw zetomuaw, jay muy roi lewi zli caumt he dafk ducr iumwij qivtkuhuyf.
Uf u qudu kesu, qiu yix cu cujdovufg qes RkiggAI fajk isko xfup. Ut iwal qitziphf quj gost mpur id ol bemu. Qgux ug wxu semv an duwg hopqjp eg ev giceb joe yeutxuogalze fini lac pmolk olgocj nqo feyuz ad fezo refsodn.
Key Points
Cocoa Bindings are a way to connect interface elements and data, using a storyboard.
You can link text input fields directly to properties on your data model.
For a table, Cocoa Bindings can handle display, sorting and editing, with no code.
Where to Go From Here?
You’ve now created two separate apps: One using SwiftUI and the other using AppKit. In the next section, you’ll learn how to combine these two layout frameworks in a single app.
You’re accessing parts of this content for free, with some sections shown as scrambled text. Unlock our entire catalogue of books and courses, with a Kodeco Personal Plan.