59 |
|
OBBond *bond; |
60 |
|
std::vector<OBEdgeBase*>::iterator bi; |
61 |
|
std::vector<int> electron; |
62 |
< |
int BO; |
63 |
< |
int sume, orden, bestorden, bestatom; |
62 |
> |
int sume, orden, bestatom; |
63 |
> |
int bestorden = 99; |
64 |
|
// Init the kekulized bonds |
65 |
|
unsigned i; |
66 |
< |
for(i=0; i< NumBonds(); i++ ) { |
67 |
< |
bond = GetBond(i); |
68 |
< |
BO = bond->GetBO(); |
69 |
< |
switch (BO) |
66 |
> |
FOR_BONDS_OF_MOL(bond, *this) |
67 |
|
{ |
68 |
< |
case 1: bond->SetKSingle(); break; |
69 |
< |
case 2: bond->SetKDouble(); break; |
70 |
< |
case 3: bond->SetKTriple(); break; |
68 |
> |
switch (bond->GetBO()) |
69 |
> |
{ |
70 |
> |
case 1: bond->SetKSingle(); break; |
71 |
> |
case 2: bond->SetKDouble(); break; |
72 |
> |
case 3: bond->SetKTriple(); break; |
73 |
> |
} |
74 |
|
} |
75 |
– |
} |
75 |
|
|
76 |
|
// Find all the groups of aromatic cycle |
77 |
|
for(i=1; i<= NumAtoms(); i++ ) { |
346 |
|
bond = GetBond(i); |
347 |
|
// std::cout << "bond " << bond->GetBeginAtomIdx() << " " << bond->GetEndAtomIdx() << " "; |
348 |
|
if (bond->GetBO()==5 && bcurrentState[i] == DOUBLE) { |
349 |
+ |
if ( (bond->GetBeginAtom())->IsSulfur() |
350 |
+ |
&& bond->GetEndAtom()->IsSulfur() ) { |
351 |
+ |
// no double bonds between aromatic sulfur atoms -- PR#1504089 |
352 |
+ |
continue; |
353 |
+ |
} |
354 |
+ |
|
355 |
|
bond->SetKDouble(); |
356 |
|
bond->SetBO(2); |
357 |
|
//std::cout << "double\n"; |