385
385
if (bsp == NULL) return;
386
386
if (! ISA_na (bsp->mol)) return;
388
desc = ValNodeNew (NULL);
388
desc = SeqDescrNew (NULL);
389
389
desc->choice = Annot_descr_name;
390
390
desc->data.ptrvalue = StringSave ("cutsites");
12734
12734
/* If either sequence is not raw and not indexer version, do not allow sequence update */
12735
12735
return FALSE;
12737
else if ((upp->salp == NULL || ignore_alignment) && action == eSequenceUpdatePatch)
12737
else if (action == eSequenceUpdatePatch
12738
&& (upp->salp == NULL || ignore_alignment
12739
|| (! RawSequencePatchOk (upp->orig_bsp, upp->update_bsp)
12740
&& !DeltaSequencePatchOk (upp->orig_bsp, upp->update_bsp))))
12739
/* If no alignment then disable the patch button */
12742
/* If no alignment or patch not available then disable the patch button */
12740
12743
return FALSE;
12742
12745
else if (ignore_alignment
15345
ptr = StringChr (id_txt2, '.');
15346
if (ptr != NULL) /* ID in list has version */
15348
len = StringLen (id_txt1);
15349
if (len == ptr - id_txt2 && StringNCmp (id_txt1, id_txt2, len) == 0)
15341
15355
sip_list = sip_list->next;
17223
17237
Char path [PATH_MAX];
17224
17238
ReadBufferData rbd;
17225
17239
CharPtr line, ptr;
17226
SeqIdPtr sip_orig, sip_update;
17240
SeqIdPtr sip_1, sip_2, sip_orig, sip_update;
17227
17241
BioseqPtr bsp_orig, bsp_update;
17228
17242
Int4 orig_position, update_position;
17229
17243
ValNodePtr update_vnp;
17255
17269
ptr += StringCSpn (ptr, "\t ");
17256
17270
if (*ptr != 0 && ptr != line)
17272
/* truncate string after first ID */
17259
/* original ID first on line, followed by tab, followed by update ID */
17260
sip_orig = MakeSeqID (line);
17261
sip_update = MakeSeqID (ptr + 1);
17263
bsp_orig = FindBioseqInList (usfp->no_updates_list, sip_orig, &orig_position);
17264
bsp_update = FindBioseqInList (usfp->unmatched_updates_list, sip_update, &update_position);
17275
/* skip over any white space before second ID */
17276
ptr += StringSpn (ptr, "\t ");
17277
/* truncate trailing white space */
17278
while (*(ptr + StringLen (ptr) - 1) == ' ' || *(ptr + StringLen (ptr) - 1) == '\t')
17280
*(ptr + StringLen (ptr) - 1) = 0;
17283
sip_1 = MakeSeqID (line);
17284
sip_2 = MakeSeqID (ptr);
17286
/* try to determine which is original and which is update */
17287
bsp_orig = FindBioseqInList (usfp->no_updates_list, sip_1, &orig_position);
17288
bsp_update = FindBioseqInList (usfp->unmatched_updates_list, sip_2, &update_position);
17289
if (bsp_orig == NULL && bsp_update == NULL)
17291
bsp_orig = FindBioseqInList (usfp->no_updates_list, sip_2, &orig_position);
17292
bsp_update = FindBioseqInList (usfp->unmatched_updates_list, sip_1, &update_position);
17294
sip_update = sip_1;
17299
sip_update = sip_2;
17265
17302
if (bsp_orig != NULL && bsp_update != NULL)
17267
17304
/* remove Bioseq from no update list and add to list of originals */