4898
static void OpenNewAlignmentEditor (SeqAlignPtr salp, Uint2 input_entityID)
4899
extern void OpenNewAlignmentEditor (SeqAlignPtr salp, Uint2 input_entityID)
4903
ModalAcceptCancelData acd;
4903
4910
if (salp == NULL)
4914
if (salp->segtype != SAS_DENSEG)
4916
w = ModalWindow (-50, -33, -10, -10, NULL);
4917
h = HiddenGroup (w, -1, 0, NULL);
4918
SetGroupSpacing (h, 10, 10);
4919
ppt = StaticPrompt (h, "Warning! You have a pairwise alignment. Some functions may not be available.",
4920
0, dialogTextHeight, programFont, 'l');
4921
c = HiddenGroup (h, 4, 0, NULL);
4922
b = PushButton (c, "Continue anyway", ModalAcceptButton);
4923
SetObjectExtra (b, &acd, NULL);
4924
b = PushButton (c, "Convert alignment", ModalThirdOptionButton);
4925
SetObjectExtra (b, &acd, NULL);
4926
b = PushButton (c, "Cancel", ModalCancelButton);
4927
SetObjectExtra (b, &acd, NULL);
4929
acd.accepted = FALSE;
4930
acd.cancelled = FALSE;
4931
acd.third_option = FALSE;
4933
AlignObjects (ALIGN_CENTER, (HANDLE) ppt, (HANDLE) c, NULL);
4938
while (!acd.accepted && ! acd.cancelled && ! acd.third_option)
4940
ProcessExternalEvent ();
4949
else if (acd.third_option)
4953
sanp = GetSeqAnnotForAlignment (salp);
4954
ConvertPairwiseToMultipleAlignment (salp);
4955
ObjMgrSetDirtyFlag (input_entityID, TRUE);
4956
ObjMgrSendMsg (OM_MSG_UPDATE, input_entityID, 0, 0);